/* Doctor Albert — ayudante de preguntas frecuentes (sin IA).
   Se coloca a la izquierda del botón flotante de WhatsApp (.wa-float,
   right:18px bottom:18px) para no taparlo ni al carrito (.cart-fab,
   right:20px bottom:92px). */
.mascota-root{
  position:fixed;
  right:86px;
  bottom:18px;
  z-index:92;
  width:76px;
  height:76px;
  font-family:var(--ff-b,"Open Sans",system-ui,sans-serif);
  color:#1B2533;
  line-height:1.45;
  -webkit-tap-highlight-color:transparent;
}
.mascota-toggle{
  position:relative;
  width:76px;
  height:76px;
  padding:0;
  border:0;
  background:transparent;
  cursor:pointer;
  border-radius:50%;
  display:grid;
  place-items:center;
  filter:drop-shadow(0 0 0.7px #0B2E59) drop-shadow(0 8px 16px rgba(11,46,89,.34));
}
.mascota-toggle:hover{transform:translateY(-1px)}
.mascota-toggle:focus-visible{outline:3px solid #F5B21B;outline-offset:3px}
.mascota-toggle{overflow:visible;border-radius:0}
.mascota-toggle .mascota-avatar{width:76px;height:76px;display:block;object-fit:cover;object-position:50% 4%;animation:mascota-bob 3.6s ease-in-out infinite;pointer-events:none;-webkit-user-select:none;user-select:none}
@keyframes mascota-bob{
  0%,100%{transform:translateY(0)}
  50%{transform:translateY(-4px)}
}

/* Hint opcional */
.mascota-hint{
  position:absolute;
  right:calc(100% + 10px);
  bottom:12px;
  background:#fff;
  color:#0B2E59;
  border:1px solid #DCE6F2;
  border-radius:14px 14px 4px 14px;
  padding:8px 12px;
  font-family:var(--ff-h,"Montserrat",system-ui,sans-serif);
  font-weight:700;
  font-size:.8rem;
  white-space:nowrap;
  box-shadow:0 8px 24px rgba(11,46,89,.12);
  animation:mascota-hint-in .4s ease;
  pointer-events:none;
}
@keyframes mascota-hint-in{from{opacity:0;transform:translateX(8px)}to{opacity:1;transform:none}}

/* Panel */
.mascota-panel{
  position:fixed;
  right:18px;
  bottom:110px;
  z-index:92;
  width:min(360px,calc(100vw - 24px));
  max-height:min(580px,calc(100dvh - 124px));
  display:none;
  flex-direction:column;
  background:#fff;
  border:1px solid #DCE6F2;
  border-radius:20px;
  box-shadow:0 16px 48px rgba(11,46,89,.2);
  overflow:hidden;
}
.mascota-root.is-open .mascota-panel{display:flex}
.mascota-root.is-open .mascota-hint{display:none}

.mascota-head{
  display:flex;
  align-items:center;
  gap:10px;
  padding:10px 10px 10px 12px;
  background:linear-gradient(180deg,#0B2E59,#0F4C97);
  color:#fff;
}
.mascota-head .mascota-avatar{width:92px;height:120px;flex:none;object-fit:contain;object-position:center bottom;filter:drop-shadow(0 4px 8px rgba(0,0,0,.25));pointer-events:none;-webkit-user-select:none;user-select:none}
.mascota-head-txt{flex:1;min-width:0}
.mascota-head-txt strong{
  display:block;
  font-family:var(--ff-h,"Montserrat",system-ui,sans-serif);
  font-weight:800;
  font-size:1.05rem;
  letter-spacing:.01em;
  color:#fff;
}
.mascota-head-txt span{display:block;font-size:.75rem;opacity:.86;margin-top:2px}
.mascota-close{
  flex:none;
  width:40px;height:40px;
  border:0;border-radius:50%;
  background:rgba(255,255,255,.12);
  color:#fff;
  cursor:pointer;
  display:grid;place-items:center;
  font-size:1.3rem;line-height:1;
}
.mascota-close:hover{background:rgba(255,255,255,.22)}
.mascota-close:focus-visible{outline:3px solid #F5B21B;outline-offset:2px}

.mascota-body{
  padding:12px 12px 8px;
  overflow:auto;
  overscroll-behavior:contain;
  flex:1;
  background:#F5F9FE;
}
.mascota-msg{
  background:#fff;
  border:1px solid #DCE6F2;
  border-radius:4px 16px 16px 16px;
  padding:12px 14px;
  font-size:.92rem;
  margin:0 0 10px;
  color:#1B2533;
}
.mascota-msg p{margin:0 0 .6em}
.mascota-msg p:last-child{margin:0}
.mascota-msg ul{
  margin:.45em 0 0;
  padding:0;
  list-style:none;
  display:flex;
  flex-direction:column;
  gap:6px;
}
.mascota-msg a{
  color:#1565C0;
  font-weight:600;
  text-decoration:none;
}
.mascota-msg a:hover{text-decoration:underline}

.mascota-faqs{display:flex;flex-direction:column;gap:8px}
.mascota-faq{
  display:block;
  width:100%;
  text-align:left;
  background:#fff;
  color:#0B2E59;
  border:1px solid #CFE4FA;
  border-radius:999px;
  padding:9px 14px;
  font-family:var(--ff-h,"Montserrat",system-ui,sans-serif);
  font-weight:700;
  font-size:.82rem;
  cursor:pointer;
  line-height:1.3;
  transition:background .15s,border-color .15s,transform .15s;
}
.mascota-faq:hover{background:#E6F1FC;border-color:#3D8BE0;transform:translateY(-1px)}
.mascota-faq:focus-visible{outline:3px solid #F5B21B;outline-offset:2px}

.mascota-answer[hidden],.mascota-faqs[hidden]{display:none}
.mascota-volver{
  display:inline-flex;
  align-items:center;
  gap:6px;
  margin:2px 0 8px;
  padding:8px 12px;
  border:0;
  background:transparent;
  color:#1565C0;
  font-family:var(--ff-h,"Montserrat",system-ui,sans-serif);
  font-weight:700;
  font-size:.85rem;
  cursor:pointer;
  border-radius:8px;
}
.mascota-volver:hover{background:#E6F1FC}
.mascota-volver:focus-visible{outline:3px solid #F5B21B;outline-offset:2px}

.mascota-foot{padding:10px 14px 14px;background:#F5F9FE;border-top:1px solid #DCE6F2}
.mascota-wa{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  width:100%;
  min-height:46px;
  padding:10px 16px;
  border-radius:999px;
  background:#128C4A;
  color:#fff !important;
  font-family:var(--ff-h,"Montserrat",system-ui,sans-serif);
  font-weight:700;
  font-size:.9rem;
  text-decoration:none !important;
  box-sizing:border-box;
}
.mascota-wa:hover{background:#0E7139}
.mascota-wa:focus-visible{outline:3px solid #F5B21B;outline-offset:2px}
.mascota-wa svg{width:20px;height:20px;flex:none}

/* Animaciones del SVG */
@media (max-width:600px){
  .mascota-root{right:82px;bottom:16px;width:68px;height:68px}
  .mascota-toggle,.mascota-toggle .mascota-avatar{width:68px;height:68px}
  .mascota-panel{
    left:12px;
    right:12px;
    width:auto;
    bottom:100px;
    max-height:calc(100dvh - 116px);
  }
  .mascota-head .mascota-avatar{width:80px;height:104px}
  .mascota-hint{font-size:.75rem;padding:7px 10px}
}
@media (prefers-reduced-motion:reduce){
  .mascota-toggle .mascota-avatar,
  .mascota-hint{animation:none !important}
  .mascota-toggle:hover,
  .mascota-faq:hover{transform:none}
}
