.sam-chatbot {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 1200;
  font-family: "Inter", Arial, sans-serif;
}

.sam-launcher {
  position: relative;
  width: 82px;
  height: 82px;
  padding: 0;
  overflow: hidden;
  border: 2px solid #82ff3e;
  border-radius: 50%;
  color: white;
  background: radial-gradient(circle at 50% 36%, #193619, #030603 72%);
  box-shadow: 0 14px 30px rgba(0,0,0,.5);
  cursor: pointer;
  transition: transform .2s ease, border-color .2s ease;
}

.sam-launcher:hover { transform: translateY(-3px) scale(1.025); border-color: #b7ff52; }
.sam-launcher img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 24%; transform: scale(1.12) translateY(5px); }
.sam-launcher::after { content:""; position:absolute; right:5px; bottom:7px; width:12px; height:12px; border:3px solid #071007; border-radius:50%; background:#82ff3e; }
.sam-unread { position:absolute; z-index:3; left:-5px; right:auto; top:-7px; width:25px; height:25px; display:grid; place-items:center; border:3px solid #050806; border-radius:50%; color:#fff; background:#ff3b30; box-shadow:0 4px 12px rgba(255,59,48,.45); font-size:12px; font-weight:800; line-height:1; pointer-events:none; animation:sam-unread-pulse 2.2s ease-in-out infinite; }
.sam-chatbot.is-open .sam-unread,.sam-chatbot.is-read .sam-unread { display:none; }

.sam-panel {
  position: absolute;
  right: 0;
  bottom: 98px;
  width: min(370px, calc(100vw - 32px));
  max-height: min(590px, calc(100vh - 132px));
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(130,255,62,.42);
  border-radius: 24px;
  color: #f7f8f6;
  background: #050806;
  box-shadow: 0 26px 70px rgba(0,0,0,.7);
  opacity: 0;
  pointer-events: none;
  transform: translateY(14px) scale(.97);
  transform-origin: right bottom;
  transition: opacity .2s ease, transform .2s ease;
}

.sam-chatbot.is-open .sam-panel { opacity: 1; pointer-events: auto; transform: translateY(0) scale(1); }
.sam-chatbot.is-open .sam-launcher { border-color: rgba(130,255,62,.55); }

.sam-header {
  min-height: 78px;
  display: grid;
  grid-template-columns: 52px 1fr 42px;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(130,255,62,.18);
  background: linear-gradient(120deg, #0b1d10, #050806 68%);
}

.sam-header-avatar { width:52px; height:52px; overflow:hidden; border:1px solid rgba(130,255,62,.55); border-radius:50%; background:#071007; }
.sam-header-avatar img { width:100%; height:100%; object-fit:cover; object-position:50% 24%; transform:scale(1.12) translateY(3px); }
.sam-header strong { display:block; font:600 18px/1 "Oxanium",sans-serif; }
.sam-header span { display:block; margin-top:5px; color:#b7ff52; font-size:11px; }
.sam-close { width:42px; height:42px; border:1px solid rgba(255,255,255,.22); border-radius:50%; color:white; background:transparent; font-size:24px; line-height:1; cursor:pointer; }
.sam-close:hover { color:#82ff3e; border-color:#82ff3e; }

.sam-messages { min-height:180px; flex:1; overflow-y:auto; display:flex; flex-direction:column; gap:10px; padding:18px 16px 10px; scrollbar-color:#315c2d #080b08; scrollbar-width:thin; }
.sam-message { max-width:88%; margin:0; padding:11px 13px; border-radius:15px; font-size:12.5px; line-height:1.45; }
.sam-message--bot { align-self:flex-start; border:1px solid rgba(130,255,62,.2); border-bottom-left-radius:4px; background:#0c160e; }
.sam-message--user { align-self:flex-end; border-bottom-right-radius:4px; color:#071006; background:#82ff3e; font-weight:700; }
.sam-message-actions { display:flex; flex-wrap:wrap; gap:6px; margin-top:9px; }
.sam-message-actions a { display:inline-flex; align-items:center; min-height:30px; padding:6px 9px; border:1px solid rgba(130,255,62,.42); border-radius:999px; color:#b7ff52; font-size:10.5px; font-weight:700; text-decoration:none; }
.sam-message-actions a:hover { color:#071006; background:#82ff3e; }

.sam-quick-replies { display:flex; flex-wrap:wrap; gap:7px; padding:6px 16px 12px; }
.sam-quick-replies button { min-height:34px; padding:7px 10px; border:1px solid rgba(130,255,62,.34); border-radius:999px; color:#edf0ec; background:#071009; font-size:10.5px; font-weight:700; cursor:pointer; transition:color .18s ease,border-color .18s ease,background .18s ease; }
.sam-quick-replies button:hover { color:#091008; border-color:#82ff3e; background:#82ff3e; }

.sam-form { display:grid; grid-template-columns:1fr 46px; gap:8px; padding:12px 14px 14px; border-top:1px solid rgba(255,255,255,.1); background:#030503; }
.sam-form input { width:100%; height:44px; padding:0 13px; border:1px solid rgba(255,255,255,.25); border-radius:11px; color:white; background:#090c09; font:12px "Inter",Arial,sans-serif; outline:none; }
.sam-form input::placeholder { color:#8f958f; }
.sam-form input:focus { border-color:#82ff3e; box-shadow:0 0 0 3px rgba(130,255,62,.1); }
.sam-send { width:46px; height:44px; display:grid; place-items:center; border:0; border-radius:11px; color:#071006; background:#82ff3e; cursor:pointer; }
.sam-send svg { width:21px; height:21px; fill:none; stroke:currentColor; stroke-width:2; stroke-linecap:round; stroke-linejoin:round; }

.sam-launcher:focus-visible,.sam-close:focus-visible,.sam-quick-replies button:focus-visible,.sam-message-actions a:focus-visible,.sam-send:focus-visible { outline:3px solid #f7f8f6; outline-offset:3px; }

@media (max-width: 620px) {
  .sam-chatbot { right:14px; bottom:14px; }
  .sam-launcher { width:70px; height:70px; }
  .sam-panel { bottom:82px; max-height:calc(100vh - 108px); border-radius:20px; }
}

@media (prefers-reduced-motion: reduce) {
  .sam-launcher,.sam-panel,.sam-unread { transition:none; animation:none; }
}

@keyframes sam-unread-pulse {
  0%,70%,100% { transform:scale(1); }
  82% { transform:scale(1.14); }
}
