
:root{
  --bouqie-cream:#fbf7ef;
  --bouqie-paper:#ffffff;
  --bouqie-ink:#22201e;
  --bouqie-muted:#756f69;
  --bouqie-pink:#9e5b77;
  --bouqie-pink-deep:#7d3e5c;
  --bouqie-line:#e9dfd5;
  --bouqie-green:#dce8db;
}

.bouqie-root{
  position:fixed;
  right:20px;
  bottom:20px;
  z-index:99990;
  font-family:inherit;
}

.bouqie-launcher{
  border:0;
  border-radius:999px;
  background:var(--bouqie-pink);
  color:#fff;
  padding:13px 18px;
  display:flex;
  align-items:center;
  gap:9px;
  box-shadow:0 12px 28px rgba(80,48,60,.22);
  cursor:pointer;
  font-size:14px;
  font-weight:700;
}

.bouqie-launcher:hover{background:var(--bouqie-pink-deep)}
.bouqie-flower{font-size:18px}

.bouqie-panel{
  position:absolute;
  right:0;
  bottom:62px;
  width:min(390px,calc(100vw - 28px));
  max-height:min(680px,calc(100dvh - 110px));
  background:var(--bouqie-paper);
  border:1px solid var(--bouqie-line);
  border-radius:18px;
  box-shadow:0 22px 55px rgba(35,28,31,.22);
  overflow:hidden;
}

.bouqie-header{
  background:var(--bouqie-cream);
  padding:15px 16px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  border-bottom:1px solid var(--bouqie-line);
}

.bouqie-header strong{
  display:block;
  font-family:Georgia,"Times New Roman",serif;
  font-size:21px;
  font-weight:400;
}
.bouqie-header small{display:block;color:var(--bouqie-muted);margin-top:2px}
.bouqie-close{
  width:34px;height:34px;border-radius:50%;
  border:1px solid var(--bouqie-line);
  background:#fff;cursor:pointer;font-size:22px;line-height:1;
}

.bouqie-body{
  padding:15px;
  overflow-y:auto;
  max-height:calc(min(680px,100dvh - 110px) - 65px);
  background:#fff;
}

.bouqie-message{
  padding:12px 13px;
  border-radius:14px;
  margin-bottom:12px;
  font-size:14px;
}
.bouqie-message p{margin:5px 0 0}
.bouqie-message-bot{background:var(--bouqie-cream);color:var(--bouqie-ink)}
.bouqie-message-user{background:var(--bouqie-pink);color:#fff;margin-left:36px}

.bouqie-question{margin:15px 0}
.bouqie-question h4{font-size:15px;margin:0 0 10px;color:var(--bouqie-ink)}
.bouqie-options{display:flex;flex-wrap:wrap;gap:8px}
.bouqie-chip{
  border:1px solid var(--bouqie-line);
  background:#fff;
  color:var(--bouqie-ink);
  border-radius:999px;
  padding:9px 12px;
  cursor:pointer;
  font-size:13px;
}
.bouqie-chip:hover,.bouqie-chip.is-selected{
  border-color:var(--bouqie-pink);
  color:var(--bouqie-pink-deep);
  background:#fbf3f6;
}

.bouqie-input,.bouqie-select,.bouqie-textarea{
  width:100%;
  border:1px solid var(--bouqie-line);
  border-radius:10px;
  padding:11px 12px;
  font:inherit;
  color:var(--bouqie-ink);
  background:#fff;
}
.bouqie-textarea{min-height:78px;resize:vertical}
.bouqie-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.bouqie-actions{display:flex;gap:9px;margin-top:13px}
.bouqie-primary,.bouqie-secondary{
  border-radius:10px;padding:11px 14px;cursor:pointer;font:inherit;font-weight:700;
}
.bouqie-primary{background:var(--bouqie-pink);color:#fff;border:1px solid var(--bouqie-pink)}
.bouqie-secondary{background:#fff;color:var(--bouqie-ink);border:1px solid var(--bouqie-line)}
.bouqie-primary:hover{background:var(--bouqie-pink-deep)}
.bouqie-summary{background:#faf8f5;border:1px solid var(--bouqie-line);border-radius:12px;padding:12px;font-size:13px}
.bouqie-summary dl{display:grid;grid-template-columns:110px 1fr;gap:5px 8px;margin:0}
.bouqie-summary dt{color:var(--bouqie-muted)}
.bouqie-summary dd{margin:0}
.bouqie-consent{
  display:flex;gap:8px;align-items:flex-start;
  margin:12px 0;font-size:12px;color:var(--bouqie-muted)
}
.bouqie-status{font-size:13px;margin-top:9px}
.bouqie-status.error{color:#9b2e2e}
.bouqie-status.success{color:#287443}

@media(max-width:640px){
  .bouqie-root{right:12px;bottom:12px}
  .bouqie-launcher-label{display:inline}
  .bouqie-panel{
    position:fixed;
    left:10px;right:10px;bottom:72px;
    width:auto;
    max-height:calc(100dvh - 92px);
  }
  .bouqie-body{max-height:calc(100dvh - 160px)}
  .bouqie-grid{grid-template-columns:1fr}
}

@media(prefers-reduced-motion:reduce){
  .bouqie-launcher,.bouqie-chip,.bouqie-primary{transition:none}
}


/* ---------------------------------------------------------
   Theme integration
   The Bows & Bouquets theme originally included a visual-only
   Bouqie prototype. Once this real plugin is active, hide that
   prototype so customers see only one Bouqie.
   --------------------------------------------------------- */
button.bouqie-fab{
  display:none !important;
}
aside.bouqie-panel:not(#bouqie-panel){
  display:none !important;
}


/* ---------------------------------------------------------
   v1.2 critical compatibility fix
   The Bows & Bouquets theme has its own legacy `.bouqie-panel`
   prototype rule with `display:none`.  The real plugin panel
   shares that class, so clicking the launcher changed the HTML
   hidden state but the theme CSS still kept it invisible.

   ID-scoped rules below make the plugin panel authoritative.
   --------------------------------------------------------- */
#bouqie-root #bouqie-panel[hidden]{
  display:none !important;
}

#bouqie-root #bouqie-panel:not([hidden]){
  display:block !important;
}

/* Keep the real plugin's body sizing independent from legacy theme rules. */
#bouqie-root #bouqie-panel .bouqie-body{
  display:block !important;
  padding:15px !important;
  overflow-y:auto !important;
  max-height:calc(min(680px, 100dvh - 110px) - 65px) !important;
}

/* Keep the actual plugin launcher visible even though the old theme FAB is hidden. */
#bouqie-root .bouqie-launcher{
  display:flex !important;
}


/* Google Maps / Places delivery address autocomplete */
.bouqie-help{
  margin:0 0 9px;
  font-size:12px;
  color:var(--bouqie-muted);
}
.bouqie-address-wrap{
  position:relative;
  width:100%;
}
.bouqie-address-input{
  width:100%;
  min-height:46px;
  padding:11px 13px;
  border:1px solid var(--bouqie-line);
  border-radius:10px;
  background:#fff;
  color:var(--bouqie-ink);
  font:inherit;
  font-size:14px;
  outline:none;
}
.bouqie-address-input:focus{
  border-color:#9e5b77;
  box-shadow:0 0 0 3px rgba(158,91,119,.12);
}
.bouqie-address-suggestions{
  position:absolute;
  z-index:2147483647;
  left:0;
  right:0;
  top:calc(100% + 5px);
  max-height:220px;
  overflow:auto;
  background:#fff;
  border:1px solid var(--bouqie-line);
  border-radius:10px;
  box-shadow:0 12px 30px rgba(49,25,35,.16);
}
.bouqie-address-suggestion{
  display:block;
  width:100%;
  padding:11px 12px;
  border:0;
  border-bottom:1px solid var(--bouqie-line);
  background:#fff;
  color:var(--bouqie-ink);
  text-align:left;
  font:inherit;
  font-size:13px;
  line-height:1.4;
  cursor:pointer;
}
.bouqie-address-suggestion:last-child{border-bottom:0;}
.bouqie-address-suggestion:hover,
.bouqie-address-suggestion:focus{
  background:var(--bouqie-cream);
  outline:none;
}
.bouqie-address-status{
  min-height:17px;
  margin:7px 0 0;
  font-size:11px;
  line-height:1.4;
  color:var(--bouqie-muted);
}
.bouqie-selected-address{
  margin-top:10px;
  padding:10px 12px;
  border:1px solid var(--bouqie-line);
  border-radius:10px;
  background:var(--bouqie-cream);
  color:var(--bouqie-ink);
  font-size:13px;
  line-height:1.45;
}
.bouqie-primary:disabled{
  opacity:.5;
  cursor:not-allowed;
}


/* Immediate contact choices */
.bouqie-quick-contact{
  margin:0 0 14px;
  padding:12px;
  border:1px solid var(--bouqie-line);
  border-radius:14px;
  background:#fff;
}
.bouqie-quick-copy strong{
  display:block;
  font-size:14px;
  color:var(--bouqie-ink);
}
.bouqie-quick-copy span{
  display:block;
  margin-top:3px;
  font-size:12px;
  line-height:1.4;
  color:var(--bouqie-muted);
}
.bouqie-quick-actions{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:8px;
  margin-top:10px;
}
.bouqie-quick-btn{
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:42px;
  padding:9px 11px;
  border-radius:10px;
  text-decoration:none !important;
  font-size:13px;
  font-weight:700;
}
.bouqie-whatsapp-btn{
  background:var(--bouqie-pink);
  color:#fff !important;
  border:1px solid var(--bouqie-pink);
}
.bouqie-call-btn{
  background:#fff;
  color:var(--bouqie-ink) !important;
  border:1px solid var(--bouqie-line);
}
.bouqie-whatsapp-btn:hover{
  background:var(--bouqie-pink-deep);
}
.bouqie-call-btn:hover{
  border-color:var(--bouqie-pink);
  color:var(--bouqie-pink-deep) !important;
}


.bouqie-profile-notice{
  margin-top:9px;
  padding:9px 10px;
  border:1px solid var(--bouqie-line);
  border-radius:10px;
  background:var(--bouqie-cream);
  color:var(--bouqie-muted);
  line-height:1.4;
}


/* v2.3 final order handoff */
#bouqie-root .bouqie-launcher[aria-expanded="true"]{
  display:none !important;
}

#bouqie-final-actions{
  display:grid;
  grid-template-columns:minmax(0,1.35fr) minmax(0,1fr);
  gap:10px;
}

#bouqie-final-actions .bouqie-submit-order{
  min-height:52px;
  font-size:16px;
}

#bouqie-final-actions .bouqie-secondary{
  min-height:52px;
}

@media(max-width:520px){
  #bouqie-final-actions{
    grid-template-columns:1fr;
  }

  #bouqie-final-actions .bouqie-submit-order{
    width:100%;
  }

  #bouqie-final-actions .bouqie-secondary{
    width:100%;
  }
}


/* v2.7 Google Place Autocomplete web component */
.bouqie-google-address-host{
  width:100%;
  position:relative;
  z-index:20;
}
.bouqie-google-address-host gmp-place-autocomplete{
  display:block;
  width:100%;
  min-height:48px;
  --gmpx-color-surface:#ffffff;
  --gmpx-color-on-surface:#3d2530;
  --gmpx-color-primary:#9e5b77;
  --gmpx-font-family:inherit;
}
.bouqie-address-loading{
  min-height:46px;
  display:flex;
  align-items:center;
  padding:11px 13px;
  border:1px solid var(--bouqie-line);
  border-radius:10px;
  background:#fff;
  color:var(--bouqie-muted);
  font-size:13px;
}
/* Google's legacy pac-container is appended to body, so it needs to sit above Bouqie. */
.pac-container{
  z-index:2147483647 !important;
}

/* v2.8 Bouqie-owned Google address suggestion list.
   We render the dropdown ourselves so it remains visible inside the scrolling chat panel. */
#bouqie-root .bouqie-address-wrap{
  position:relative;
  width:100%;
  overflow:visible !important;
  z-index:120;
}
#bouqie-root .bouqie-address-input{
  width:100%;
  min-height:52px;
  padding:12px 14px;
  border:1px solid #6c5a61;
  border-radius:4px;
  background:#fff;
  color:#1f171a;
  font:inherit;
  font-size:16px;
  outline:none;
}
#bouqie-root .bouqie-address-input:focus{
  border-color:#9e5b77;
  box-shadow:0 0 0 3px rgba(158,91,119,.12);
}
#bouqie-root .bouqie-address-suggestions{
  position:relative;
  width:100%;
  margin-top:6px;
  max-height:260px;
  overflow-y:auto;
  border:1px solid #dccbd2;
  border-radius:10px;
  background:#fff;
  box-shadow:0 12px 30px rgba(61,37,48,.18);
  z-index:2147483000;
}
#bouqie-root .bouqie-address-suggestions[hidden]{display:none !important;}
#bouqie-root .bouqie-address-suggestion{
  display:block;
  width:100%;
  padding:13px 14px;
  border:0;
  border-bottom:1px solid #eee4e8;
  background:#fff;
  color:#2a2024;
  text-align:left;
  font:inherit;
  font-size:14px;
  line-height:1.35;
  cursor:pointer;
}
#bouqie-root .bouqie-address-suggestion:last-child{border-bottom:0;}
#bouqie-root .bouqie-address-suggestion:hover,
#bouqie-root .bouqie-address-suggestion:focus{
  background:#fbf4f7;
  color:#7f3655;
  outline:none;
}
#bouqie-root .bouqie-address-empty{
  padding:13px 14px;
  color:#725e66;
  font-size:13px;
  line-height:1.4;
}
