/* ===== Theme-aligned variables (yellow/black/white like your site) ===== */
:root {
  --cb-z: 2147483000;
  --cb-accent: #ffeb3b;         /* bright yellow */
  --cb-accent-hover: #facc15;   /* darker yellow hover */
  --cb-card: #ffffff;           /* popup card */
  --cb-text: #111111;           /* dark text */
  --cb-muted: #6b7280;          /* muted gray */
  --cb-shadow: 0 12px 28px rgba(0,0,0,0.35);
  --cb-radius: 14px;
  --cb-bubble-size: 70px;       /* default; JS will override from admin */
}

/* ===== Floating bubble ===== */
.cb-callback-widget { 
  position: fixed; 
  inset: auto 22px 22px auto; 
  z-index: var(--cb-z); 
}

.cb-bubble {
  position: relative;
  width: var(--cb-bubble-size); 
  height: var(--cb-bubble-size); 
  border-radius: 999px;
  background: var(--cb-accent);
  display: grid; 
  place-items: center;
  color: #000; 
  font-weight: bold;
  border: 3px solid #000;
  cursor: pointer;
  box-shadow: var(--cb-shadow);
  animation: cb-float 6s ease-in-out infinite;
  transition: transform .2s ease, background .2s ease;
}
.cb-bubble:hover { 
  transform: scale(1.08); 
  background: var(--cb-accent-hover); 
}
.cb-icon { 
  width: calc(var(--cb-bubble-size) * 0.43); 
  height: calc(var(--cb-bubble-size) * 0.43); 
  fill: currentColor; 
}

/* soft “radar” pulse */
.cb-bubble-ping {
  position: absolute;
  inset: calc(var(--cb-bubble-size) * -0.085);
  border-radius: 999px;
  pointer-events: none;
  box-shadow: 0 0 0 0 rgba(250, 204, 21, 0.55);
  animation: cb-ping 2.2s ease-out infinite;
}

@keyframes cb-float {
  0%   { transform: translate(0, 0); }
  25%  { transform: translate(-3px, -3px); }
  50%  { transform: translate(0, -6px); }
  75%  { transform: translate(3px, -3px); }
  100% { transform: translate(0, 0); }
}

@keyframes cb-ping {
  0%   { box-shadow: 0 0 0 0 rgba(250, 204, 21, 0.55); }
  70%  { box-shadow: 0 0 0 16px rgba(250, 204, 21, 0.0); }
  100% { box-shadow: 0 0 0 0 rgba(250, 204, 21, 0.0); }
}

/* ===== CTA pill (ALWAYS visible) ===== */
.cb-cta-pill {
  position: fixed;
  right: calc(22px + var(--cb-bubble-size) + 10px); /* to the left of the bubble */
  bottom: calc(22px + (var(--cb-bubble-size) - 40px)/2);
  z-index: calc(var(--cb-z) + 1);
  background: var(--cb-accent);
  color: #000;
  border: 2px solid #000;
  font-weight: 800;
  font-size: .95rem;
  line-height: 1;
  padding: 10px 14px;
  border-radius: 999px;
  box-shadow: var(--cb-shadow);
  transform: translateY(0);
  opacity: 1;           /* always visible */
  pointer-events: auto; /* clickable if you ever want to hook it */
}
.cb-cta-pill::after {
  content: "";
  position: absolute;
  left: -7px; bottom: 10px;
  border-width: 7px 9px 7px 0;
  border-style: solid;
  border-color: transparent #000 transparent transparent;
}
.cb-cta-pill::before {
  content: "";
  position: absolute;
  left: -5px; bottom: 10px;
  border-width: 6px 8px 6px 0;
  border-style: solid;
  border-color: transparent var(--cb-accent) transparent transparent;
}

/* Mobile: stack under bubble */
@media (max-width: 640px) {
  .cb-cta-pill {
    right: 22px;
    bottom: calc(var(--cb-bubble-size) + 30px);
  }
}

/* ===== Modal ===== */
.cb-modal {
  position: fixed; 
  inset: 0; 
  display: grid; 
  place-items: center;
  background: rgba(0, 0, 0, 0.65);
  padding: 16px;
}
.cb-modal[hidden] { display: none !important; }

.cb-card {
  width: min(92vw, 360px);
  background: var(--cb-card);
  color: var(--cb-text);
  border-radius: var(--cb-radius);
  box-shadow: var(--cb-shadow);
  padding: 20px 18px 16px;
  transform: translateY(20px);
  animation: cb-pop .25s ease-out forwards;
  border-top: 6px solid var(--cb-accent);
  position: relative;
}
@keyframes cb-pop { to { transform: translateY(0); } }

.cb-title { 
  margin: 0 0 14px 0; 
  font-size: 1.25rem; 
  font-weight: 700; 
  color: #000; 
  text-align: center;
}

.cb-close {
  position: absolute; 
  right: 20px; 
  top: 14px;
  background: transparent; 
  border: none; 
  font-size: 26px; 
  line-height: 1; 
  cursor: pointer;
  color: #444;
}
.cb-close:hover { color: #000; }

.cb-field { margin-bottom: 12px; }
.cb-label { display: block; font-size: .9rem; color: #444; margin-bottom: 5px; }

.cb-input {
  width: 100%; 
  background: #f9fafb; 
  border: 1px solid #e5e7eb; 
  color: #111;
  padding: 10px 12px; 
  border-radius: 10px; 
  outline: none;
  font-size: .95rem;
}
.cb-input:focus { 
  border-color: var(--cb-accent); 
  box-shadow: 0 0 0 3px rgba(250,204,21,.3); 
}

.cb-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.cb-lang-wrap { display: flex; gap: 12px; }
.cb-radio { display: inline-flex; align-items: center; gap: 6px; font-size: .9rem; }
.cb-radio input { accent-color: var(--cb-accent); }
.cb-radio-text { user-select: none; }

.cb-captcha { display: flex; align-items: center; gap: 6px; font-weight: bold; color: #000; }
.cb-cap-input { width: 80px; text-align: center; }

.cb-button {
  width: 100%; margin-top: 10px;
  background: var(--cb-accent); 
  color: #000; 
  border: 2px solid #000;
  padding: 12px 14px; 
  border-radius: 10px; 
  font-weight: 700; 
  cursor: pointer;
  font-size: 1rem;
  transition: background .2s ease, transform .08s ease;
}
.cb-button:hover { background: var(--cb-accent-hover); }
.cb-button:active { transform: translateY(1px); }
.cb-button[disabled] { opacity: .6; cursor: not-allowed; }

.cb-privacy { margin: 8px 0 0; font-size: .8rem; color: #666; text-align: center; }
.cb-message { margin: 8px 0 0; font-size: .9rem; text-align: center; }
.cb-message.success { color: #16a34a; font-weight: bold; }
.cb-message.error { color: #dc2626; font-weight: bold; }
