
:root {
  --sit-ocean:   #0a6e8a;
  --sit-wave:    #12a0c4;
  --sit-sand:    #f5ede0;
  --sit-coral:   #e05a2b;
  --sit-dark:    #0d1f2d;
  --sit-mid:     #4a6274;
  --sit-light:   #edf4f7;
  --sit-white:   #ffffff;
  --sit-radius:  16px;
  --sit-shadow:  0 8px 40px rgba(10,110,138,.22);
}

#sit-promo {
  position: fixed;
  bottom: 96px;
  left: 24px;
  z-index: 2147483645;
  background: var(--sit-white);
  border-radius: 12px 12px 12px 4px;
  padding: 10px 14px;
  box-shadow: var(--sit-shadow);
  font-size: 13px;
  color: var(--sit-dark);
  max-width: 220px;
  line-height: 1.4;
  animation: sitSlideIn .4s ease;
  cursor: pointer;
}
#sit-promo::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 18px;
  border: 8px solid transparent;
  border-top-color: var(--sit-white);
  border-bottom: none;
}
@keyframes sitSlideIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

#sit-launcher {
  position: fixed;
  bottom: 24px;
  left: 24px;
  z-index: 2147483647;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--sit-ocean), var(--sit-wave));
  border: none;
  cursor: pointer;
  box-shadow: var(--sit-shadow);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform .2s ease;
}
#sit-launcher:hover { transform: scale(1.08); }
#sit-launcher svg { width: 28px; height: 28px; fill: var(--sit-white); }
#sit-badge {
  position: absolute;
  top: -2px; right: -2px;
  background: var(--sit-coral);
  color: #fff;
  border-radius: 50%;
  width: 18px; height: 18px;
  font-size: 11px; font-weight: 700;
  display: none;
  align-items: center; justify-content: center;
}

#sit-chat {
  position: fixed;
  bottom: 96px;
  left: 24px;
  z-index: 2147483646;
  width: 370px;
  max-height: 580px;
  display: flex;
  flex-direction: column;
  border-radius: var(--sit-radius);
  box-shadow: var(--sit-shadow);
  background: var(--sit-white);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 14px;
  transform: scale(.9) translateY(12px);
  opacity: 0;
  pointer-events: none;
  transition: transform .25s ease, opacity .25s ease;
  overflow: hidden;
}
#sit-chat.open {
  transform: scale(1) translateY(0);
  opacity: 1;
  pointer-events: all;
}

@media (max-width: 1024px) {
  #sit-chat {
    left: 0; right: 0;
    top: 0; bottom: 0;
    width: 100%;
    height: 100%;
    max-height: none;
    border-radius: 0;
  }
  #sit-launcher { bottom: 16px; left: 16px; }
  #sit-promo { bottom: 88px; left: 16px; }
  #sit-input { font-size: 16px; }
}

#sit-header {
  background: linear-gradient(135deg, var(--sit-dark), var(--sit-ocean));
  color: var(--sit-white);
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
#sit-header .avatar {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--sit-wave);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; flex-shrink: 0;
}
#sit-header .info { flex: 1; }
#sit-header .info strong { display: block; font-size: 14px; }
#sit-header .info span {
  font-size: 11px; opacity: .75;
  display: flex; align-items: center; gap: 4px;
}
#sit-header .info span::before {
  content: ''; width: 7px; height: 7px;
  border-radius: 50%; background: #4ade80; display: inline-block;
}
#sit-close {
  background: none; border: none; color: #fff;
  cursor: pointer; padding: 4px; opacity: .7; transition: opacity .15s;
}
#sit-close:hover { opacity: 1; }
#sit-close svg { width: 20px; height: 20px; fill: #fff; }

#sit-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--sit-light);
  min-height: 0;
}
#sit-messages::-webkit-scrollbar { width: 4px; }
#sit-messages::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 4px; }

.sit-msg {
  max-width: 85%;
  padding: 10px 13px;
  border-radius: 14px;
  line-height: 1.45;
  word-break: break-word;
  white-space: pre-wrap;
}
.sit-msg.bot {
  background: var(--sit-white);
  color: var(--sit-dark);
  border-bottom-left-radius: 4px;
  align-self: flex-start;
  box-shadow: 0 1px 4px rgba(0,0,0,.08);
}
.sit-msg.user {
  background: linear-gradient(135deg, var(--sit-ocean), var(--sit-wave));
  color: var(--sit-white);
  border-bottom-right-radius: 4px;
  align-self: flex-end;
}
.sit-typing {
  display: flex; gap: 4px; align-items: center;
  padding: 12px 14px;
  background: var(--sit-white);
  border-radius: 14px;
  border-bottom-left-radius: 4px;
  align-self: flex-start;
  box-shadow: 0 1px 4px rgba(0,0,0,.08);
}
.sit-typing span {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--sit-wave);
  animation: sitBounce .9s infinite;
}
.sit-typing span:nth-child(2) { animation-delay: .15s; }
.sit-typing span:nth-child(3) { animation-delay: .3s; }
@keyframes sitBounce {
  0%,60%,100% { transform: translateY(0); }
  30% { transform: translateY(-5px); }
}

.sit-chips {
  display: flex; flex-wrap: wrap; gap: 6px;
  margin-top: 4px;
}
.sit-chip {
  background: var(--sit-white);
  border: 1.5px solid var(--sit-wave);
  color: var(--sit-ocean);
  border-radius: 20px;
  padding: 7px 16px;
  font-size: 13px;
  cursor: pointer;
  transition: background .15s, color .15s;
  font-family: inherit;
}
.sit-chip:hover { background: var(--sit-ocean); color: #fff; border-color: var(--sit-ocean); }
.sit-chips[data-step-key] .sit-chip {
  width: 100%; text-align: left; border-radius: 8px;
  padding: 10px 14px; font-size: 13.5px;
  border-color: #d1e0ea; color: var(--sit-dark);
}
.sit-chips[data-step-key] .sit-chip:hover { background: var(--sit-ocean); color: #fff; border-color: var(--sit-ocean); }
.sit-chips[data-step-key="confirm"] .sit-chip { border-radius: 24px; text-align: center; }
.sit-chips[data-step-key="confirm"] .sit-chip:first-child {
  background: linear-gradient(135deg, var(--sit-ocean), var(--sit-wave));
  color: #fff; border-color: transparent; font-weight: 700;
}

#sit-inputbar {
  display: flex;
  gap: 8px;
  padding: 12px 14px;
  border-top: 1px solid #e2eaf0;
  background: var(--sit-white);
  flex-shrink: 0;
}
#sit-input {
  flex: 1;
  border: 1.5px solid #d1e0ea;
  border-radius: 24px;
  padding: 9px 16px;
  font-size: 13.5px;
  outline: none;
  transition: border-color .2s;
  color: var(--sit-dark);
  background: var(--sit-light);
  resize: none;
  font-family: inherit;
  max-height: 80px;
  line-height: 1.4;
}
#sit-input:focus { border-color: var(--sit-wave); }
#sit-send {
  width: 40px; height: 40px; border-radius: 50%;
  background: linear-gradient(135deg, var(--sit-ocean), var(--sit-wave));
  border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: transform .15s;
  flex-shrink: 0; align-self: flex-end;
}
#sit-send:hover { transform: scale(1.08); }
#sit-send svg { width: 18px; height: 18px; fill: #fff; }
#sit-send:disabled { opacity: .5; cursor: default; transform: none; }
