/* Pro Glaçons Assistant IA - V2.3 */

.pgai-assistant,
.pgai-assistant *{
  box-sizing:border-box;
  font-family:Inter,Arial,sans-serif;
}

.pgai-assistant{
  position:fixed;
  right:22px;
  bottom:22px;
  z-index:999999;
}

.pgai-bubble{
  position:relative;
  width:62px;
  height:62px;
  border:0;
  border-radius:22px;
  cursor:pointer;
  color:#fff;
  background:
    radial-gradient(circle at 30% 20%, rgba(255,255,255,.36), transparent 28%),
    linear-gradient(135deg,#19b7ee,#2488ff);
  box-shadow:0 18px 38px rgba(36,136,255,.32);
  display:flex;
  align-items:center;
  justify-content:center;
  transition:transform .25s ease, box-shadow .25s ease;
}

.pgai-bubble:hover{
  transform:translateY(-3px) scale(1.03);
  box-shadow:0 22px 48px rgba(36,136,255,.42);
}

.pgai-bubble-icon{
  position:relative;
  z-index:2;
  font-size:27px;
  line-height:1;
}

.pgai-bubble-pulse{
  position:absolute;
  inset:0;
  border-radius:22px;
  animation:pgaiPulse 2s infinite;
}

@keyframes pgaiPulse{
  0%{box-shadow:0 0 0 0 rgba(36,136,255,.45);}
  75%{box-shadow:0 0 0 18px rgba(36,136,255,0);}
  100%{box-shadow:0 0 0 0 rgba(36,136,255,0);}
}

/* Petit message visible quand le chatbot est fermé */
.pgai-welcome{
  position:absolute;
  right:0;
  bottom:78px;
  width:318px;
  padding:15px 42px 15px 16px;
  border-radius:20px;
  background:#fff;
  border:1px solid #dbe8ff;
  box-shadow:0 18px 45px rgba(7,20,38,.14);
  opacity:0;
  visibility:hidden;
  transform:translateY(10px) scale(.97);
  transition:.25s ease;
  pointer-events:none;
}

.pgai-welcome:after{
  content:"";
  position:absolute;
  right:23px;
  bottom:-8px;
  width:16px;
  height:16px;
  background:#fff;
  border-right:1px solid #dbe8ff;
  border-bottom:1px solid #dbe8ff;
  transform:rotate(45deg);
}

.pgai-assistant.pgai-show-welcome:not(.pgai-open) .pgai-welcome{
  opacity:1;
  visibility:visible;
  transform:translateY(0) scale(1);
  pointer-events:auto;
}

.pgai-welcome strong{
  display:block;
  margin-bottom:6px;
  color:#071426;
  font-size:15.5px;
  line-height:1.2;
}

.pgai-welcome span{
  display:block;
  color:#60718e;
  font-size:13.5px;
  line-height:1.45;
}

.pgai-welcome-close{
  position:absolute;
  top:10px;
  right:12px;
  width:24px;
  height:24px;
  border:0;
  border-radius:8px;
  background:transparent;
  color:#e22f73;
  cursor:pointer;
  font-size:18px;
  line-height:1;
}

.pgai-welcome-close:hover{
  background:#fff1f6;
}

.pgai-panel{
  position:absolute;
  right:0;
  bottom:78px;
  width:360px;
  opacity:0;
  visibility:hidden;
  transform:translateY(14px) scale(.96);
  transform-origin:bottom right;
  transition:.25s ease;
  pointer-events:none;
}

.pgai-assistant.pgai-open .pgai-panel{
  opacity:1;
  visibility:visible;
  transform:translateY(0) scale(1);
  pointer-events:auto;
}

.pgai-card{
  overflow:hidden;
  border-radius:26px;
  background:#fff;
  border:1px solid rgba(219,233,252,.95);
  box-shadow:0 28px 70px rgba(7,20,38,.24);
}

.pgai-header{
  position:relative;
  min-height:82px;
  padding:18px 52px 18px 18px;
  display:flex;
  align-items:center;
  gap:13px;
  color:#fff;
  background:
    radial-gradient(circle at 80% -10%, rgba(36,136,255,.5), transparent 34%),
    linear-gradient(135deg,#071426,#0d2548);
}

.pgai-avatar{
  width:46px;
  height:46px;
  flex:0 0 46px;
  border-radius:16px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:rgba(255,255,255,.12);
  border:1px solid rgba(255,255,255,.16);
  font-size:23px;
}

.pgai-header strong{
  display:block;
  font-size:17px;
  line-height:1.15;
  letter-spacing:-.2px;
}

.pgai-header span{
  display:block;
  margin-top:4px;
  color:rgba(255,255,255,.72);
  font-size:13px;
}

.pgai-close{
  position:absolute;
  top:16px;
  right:16px;
  width:30px;
  height:30px;
  border:0;
  border-radius:10px;
  cursor:pointer;
  color:#fff;
  background:rgba(255,255,255,.12);
  font-size:22px;
  line-height:1;
}

.pgai-close:hover{
  background:rgba(255,255,255,.2);
}

.pgai-body{
  padding:18px;
  background:linear-gradient(180deg,#fff,#f8fbff);
}

.pgai-intro{
  margin:0 0 14px;
  color:#071426;
  font-size:15px;
  line-height:1.45;
}

.pgai-actions{
  display:flex;
  flex-direction:column;
  gap:10px;
}

.pgai-action{
  display:flex;
  align-items:center;
  gap:12px;
  padding:14px;
  border-radius:18px;
  text-decoration:none;
  color:#071426;
  background:#fff;
  border:1px solid #e3eefc;
  box-shadow:0 10px 24px rgba(7,20,38,.045);
  transition:.22s ease;
}

.pgai-action:hover{
  transform:translateY(-2px);
  border-color:#b9d8ff;
  box-shadow:0 15px 32px rgba(36,136,255,.12);
}

.pgai-action-icon{
  width:40px;
  height:40px;
  flex:0 0 40px;
  border-radius:14px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#eef6ff;
  font-size:20px;
}

.pgai-action strong{
  display:block;
  font-size:15.5px;
  line-height:1.2;
}

.pgai-action small{
  display:block;
  margin-top:4px;
  color:#60718e;
  font-size:12.5px;
  line-height:1.25;
}

.pgai-phone{
  background:linear-gradient(135deg,#071426,#10294d);
  color:#fff;
  border-color:#071426;
}

.pgai-phone small{
  color:rgba(255,255,255,.72);
}

.pgai-phone .pgai-action-icon{
  background:rgba(255,255,255,.12);
}

.pgai-footer{
  padding:13px 16px 15px;
  background:#f8fbff;
  border-top:1px solid #eef4fc;
  text-align:center;
}

.pgai-response{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  color:#18a957;
  font-size:13.5px;
  font-weight:800;
  margin-bottom:8px;
}

.pgai-status{
  width:10px;
  height:10px;
  border-radius:50%;
  background:#20c765;
  box-shadow:0 0 0 5px rgba(32,199,101,.12);
}

.pgai-signature{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:4px;
  padding:6px 12px;
  border-radius:999px;
  background:#fff;
  border:1px solid #e3eefc;
  color:#60718e;
  font-size:11.8px;
  line-height:1;
  text-decoration:none;
  transition:.22s ease;
}

.pgai-signature strong{
  color:#2488ff;
  font-weight:900;
}

.pgai-signature:hover{
  color:#071426;
  border-color:#b9d8ff;
  box-shadow:0 8px 18px rgba(36,136,255,.10);
}

@media(max-width:767px){
  .pgai-assistant{
    right:14px;
    bottom:14px;
  }

  .pgai-bubble{
    width:58px;
    height:58px;
    border-radius:20px;
  }

  .pgai-bubble-pulse{
    border-radius:20px;
  }

  .pgai-panel{
    position:fixed;
    left:14px;
    right:14px;
    bottom:84px;
    width:auto;
    transform-origin:bottom center;
  }

  .pgai-welcome{
    position:fixed;
    left:14px;
    right:14px;
    bottom:84px;
    width:auto;
    max-width:none;
  }

  .pgai-welcome:after{
    right:30px;
  }

  .pgai-card{
    border-radius:24px;
  }

  .pgai-header{
    min-height:76px;
    padding:16px 50px 16px 16px;
  }

  .pgai-body{
    padding:15px;
  }

  .pgai-action{
    padding:12px;
    border-radius:16px;
  }

  .pgai-action-icon{
    width:38px;
    height:38px;
    flex-basis:38px;
  }

  .pgai-action strong{
    font-size:15px;
  }
}
