﻿.eca-library-chatbot{
  --eca-chat-blue:#004C99;
  --eca-chat-blue-dark:#003b79;
  --eca-chat-navy:#062248;
  --eca-chat-gold:#f6a800;
  --eca-chat-text:#102947;
  bottom:22px;
  font-family:Lato, Arial, sans-serif;
  position:fixed;
  right:22px;
  z-index:9999;
}

.eca-library-chatbot *,
.eca-library-chatbot *:before,
.eca-library-chatbot *:after{
  box-sizing:border-box;
}

.eca-library-chatbot__launcher{
  align-items:center;
  background:linear-gradient(135deg, var(--eca-chat-blue), var(--eca-chat-blue-dark));
  border:0;
  border-radius:999px;
  box-shadow:0 16px 34px rgba(0, 67, 139, .28);
  color:#fff;
  cursor:pointer;
  display:flex;
  font-size:15px;
  font-weight:700;
  gap:10px;
  line-height:1;
  min-height:56px;
  padding:10px 18px 10px 10px;
  transition:box-shadow .22s ease, transform .22s ease, background .22s ease;
}

.eca-library-chatbot__launcher:hover,
.eca-library-chatbot__launcher:focus{
  background:linear-gradient(135deg, #003f80, var(--eca-chat-blue));
  box-shadow:0 18px 38px rgba(0, 67, 139, .36);
  outline:0;
  transform:translateY(-2px);
}

.eca-library-chatbot__launcher-icon{
  align-items:center;
  background:rgba(255, 255, 255, .18);
  border:1px solid rgba(255, 255, 255, .34);
  border-radius:50%;
  display:flex;
  height:38px;
  justify-content:center;
  width:38px;
}

.eca-library-chatbot__panel{
  background:#fff;
  border:1px solid rgba(0, 108, 223, .18);
  border-radius:18px;
  bottom:76px;
  box-shadow:0 24px 60px rgba(4, 35, 72, .26);
  max-height:min(680px, calc(100vh - 120px));
  overflow:hidden;
  position:absolute;
  right:0;
  transform-origin:bottom right;
  width:370px;
}

.eca-library-chatbot.is-open .eca-library-chatbot__panel{
  animation:eca-chat-open .22s ease both;
}

.eca-library-chatbot__header{
  align-items:center;
  background:
    radial-gradient(circle at 86% 12%, rgba(246, 168, 0, .2), transparent 26%),
    linear-gradient(135deg, var(--eca-chat-navy), var(--eca-chat-blue-dark));
  color:#fff;
  display:flex;
  justify-content:space-between;
  padding:18px 18px 16px;
}

.eca-library-chatbot__eyebrow{
  color:#8fd6ff;
  font-size:12px;
  font-weight:800;
  letter-spacing:.08em;
  margin:0 0 5px;
  text-transform:uppercase;
}

.eca-library-chatbot__header h2{
  color:#fff;
  font-size:19px;
  font-weight:800;
  line-height:1.2;
  margin:0;
}

.eca-library-chatbot__close{
  align-items:center;
  background:rgba(255, 255, 255, .12);
  border:1px solid rgba(255, 255, 255, .2);
  border-radius:50%;
  color:#fff;
  cursor:pointer;
  display:flex;
  height:34px;
  justify-content:center;
  padding:0;
  transition:background .2s ease, transform .2s ease;
  width:34px;
}

.eca-library-chatbot__close:hover,
.eca-library-chatbot__close:focus{
  background:rgba(255, 255, 255, .22);
  outline:0;
  transform:rotate(8deg);
}

.eca-library-chatbot__messages{
  background:
    radial-gradient(circle at 0 0, rgba(0, 108, 223, .08), transparent 32%),
    #f7fbff;
  display:flex;
  flex-direction:column;
  gap:10px;
  max-height:270px;
  min-height:190px;
  overflow-y:auto;
  padding:16px;
}

.eca-library-chatbot__message{
  border-radius:14px;
  font-size:14px;
  line-height:1.45;
  max-width:88%;
  padding:11px 13px;
}

.eca-library-chatbot__message--bot{
  align-self:flex-start;
  background:#fff;
  border:1px solid rgba(0, 108, 223, .14);
  box-shadow:0 8px 20px rgba(12, 60, 116, .08);
  color:var(--eca-chat-text);
}

.eca-library-chatbot__message--user{
  align-self:flex-end;
  background:linear-gradient(135deg, var(--eca-chat-blue), var(--eca-chat-blue-dark));
  color:#fff;
}

.eca-library-chatbot__typing{
  color:#42617f;
  font-style:italic;
}

.eca-library-chatbot__links{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  margin-top:10px;
}

.eca-library-chatbot__links a{
  align-items:center;
  background:rgba(0, 108, 223, .1);
  border-radius:999px;
  color:var(--eca-chat-blue);
  display:inline-flex;
  font-size:12px;
  font-weight:800;
  padding:6px 10px;
  text-decoration:none;
}

.eca-library-chatbot__links a:hover,
.eca-library-chatbot__links a:focus{
  background:rgba(0, 108, 223, .16);
  color:#0057b8;
  outline:0;
}

.eca-library-chatbot__actions{
  background:#fff;
  border-top:1px solid rgba(0, 108, 223, .1);
  display:grid;
  gap:10px;
  grid-template-columns:repeat(2, minmax(0, 1fr));
  padding:13px 16px 5px;
}

.eca-library-chatbot__action{
  align-items:center;
  border:1px solid rgba(0, 108, 223, .18);
  border-radius:12px;
  display:flex;
  gap:8px;
  justify-content:center;
  min-height:44px;
  padding:9px 10px;
  text-align:center;
  text-decoration:none;
  transition:background .2s ease, border-color .2s ease, box-shadow .2s ease, color .2s ease, transform .2s ease;
}

.eca-library-chatbot__action i{
  flex:0 0 auto;
  font-size:14px;
}

.eca-library-chatbot__action span{
  font-size:12px;
  font-weight:900;
  line-height:1.15;
}

.eca-library-chatbot__action--subscribe{
  background:#eef6ff;
  color:var(--eca-chat-blue);
}

.eca-library-chatbot__action--member{
  background:#fff7df;
  border-color:rgba(246, 168, 0, .38);
  color:#6b4500;
}

.eca-library-chatbot__action:hover,
.eca-library-chatbot__action:focus{
  box-shadow:0 10px 24px rgba(0, 76, 153, .13);
  outline:0;
  text-decoration:none;
  transform:translateY(-1px);
}

.eca-library-chatbot__action--subscribe:hover,
.eca-library-chatbot__action--subscribe:focus{
  background:var(--eca-chat-blue);
  border-color:var(--eca-chat-blue);
  color:#fff;
}

.eca-library-chatbot__action--member:hover,
.eca-library-chatbot__action--member:focus{
  background:var(--eca-chat-gold);
  border-color:var(--eca-chat-gold);
  color:#102947;
}

.eca-library-chatbot__quick{
  background:#fff;
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  padding:14px 16px 4px;
}

.eca-library-chatbot__quick button{
  background:#eef6ff;
  border:1px solid rgba(0, 108, 223, .18);
  border-radius:999px;
  color:#0d4587;
  cursor:pointer;
  font-size:12px;
  font-weight:800;
  padding:7px 11px;
  transition:background .2s ease, border-color .2s ease, color .2s ease;
}

.eca-library-chatbot__quick button:hover,
.eca-library-chatbot__quick button:focus{
  background:#e1f0ff;
  border-color:rgba(0, 108, 223, .36);
  color:var(--eca-chat-blue-dark);
  outline:0;
}

.eca-library-chatbot__form{
  align-items:center;
  background:#fff;
  display:flex;
  gap:8px;
  padding:14px 16px 16px;
}

.eca-library-chatbot__form input{
  background:#fff;
  border:1px solid rgba(0, 108, 223, .22);
  border-radius:12px;
  color:var(--eca-chat-text);
  flex:1;
  font-size:14px;
  min-height:44px;
  min-width:0;
  padding:0 13px;
  transition:border-color .2s ease, box-shadow .2s ease;
}

.eca-library-chatbot__form input:focus{
  border-color:rgba(0, 108, 223, .72);
  box-shadow:0 0 0 3px rgba(0, 108, 223, .12);
  outline:0;
}

.eca-library-chatbot__form button{
  align-items:center;
  background:linear-gradient(135deg, var(--eca-chat-blue), var(--eca-chat-blue-dark));
  border:0;
  border-radius:12px;
  color:#fff;
  cursor:pointer;
  display:flex;
  font-size:13px;
  font-weight:800;
  gap:7px;
  min-height:44px;
  padding:0 14px;
  transition:box-shadow .2s ease, transform .2s ease;
}

.eca-library-chatbot__form button:hover,
.eca-library-chatbot__form button:focus{
  box-shadow:0 10px 22px rgba(0, 108, 223, .24);
  outline:0;
  transform:translateY(-1px);
}

.eca-library-chatbot__form button:disabled{
  cursor:wait;
  opacity:.72;
  transform:none;
}

@keyframes eca-chat-open{
  from{
    opacity:0;
    transform:translateY(12px) scale(.98);
  }
  to{
    opacity:1;
    transform:translateY(0) scale(1);
  }
}

@media (max-width:575.98px){
  .eca-library-chatbot{
    bottom:16px;
    right:14px;
  }

  .eca-library-chatbot__launcher{
    min-height:52px;
    padding-right:14px;
  }

  .eca-library-chatbot__launcher-text{
    display:none;
  }

  .eca-library-chatbot__panel{
    bottom:66px;
    left:14px;
    max-height:calc(100vh - 94px);
    max-width:none;
    position:fixed;
    right:14px;
    width:auto;
  }

  .eca-library-chatbot__messages{
    max-height:260px;
    min-height:170px;
  }
}

@media (prefers-reduced-motion:reduce){
  .eca-library-chatbot *,
  .eca-library-chatbot *:before,
  .eca-library-chatbot *:after{
    animation-duration:.01ms !important;
    scroll-behavior:auto !important;
    transition-duration:.01ms !important;
  }
}
