.bdb-root {
  --bdb-red: #cb3522;
  font-family: Inter, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  width: 100%;
  box-sizing: border-box;
}

.bdb-root [hidden] {
  display: none !important;
}

.bdb-root button {
  -webkit-appearance: none;
  appearance: none;
  -webkit-tap-highlight-color: transparent;
}

.bdb-root button:focus,
.bdb-root button:focus-visible,
.bdb-root button:active {
  outline: none;
  box-shadow: none;
}

.bdb-dialog {
  position: relative;
  width: 100%;
  box-sizing: border-box;
  background: #f5f0e8;
  color: #1a1a1a;
  padding: 1.5rem 1.4rem 1.2rem;
}

.bdb-close {
  position: absolute;
  top: 0.55rem;
  right: 0.7rem;
  width: 2.4rem;
  height: 2.4rem;
  border: 0;
  background: transparent !important;
  background-color: transparent !important;
  color: #1a1a1a;
  font-size: 1.8rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: none !important;
  z-index: 2;
}

.bdb-close:hover,
.bdb-close:focus,
.bdb-close:focus-visible,
.bdb-close:active {
  background: transparent !important;
  background-color: transparent !important;
  color: var(--bdb-red);
}

.bdb-hero {
  flex: 0 0 auto;
  padding: 0.15rem 2.2rem 0.95rem 0.1rem;
}

.bdb-hero h2 {
  margin: 0 0 0.55rem;
  font-size: clamp(1.35rem, 3vw, 1.85rem);
  font-weight: 700;
  color: #111;
}

.bdb-hero p {
  margin: 0;
  color: #3a3a3a;
  line-height: 1.45;
  font-size: 0.96rem;
}

.bdb-thread {
  width: 100%;
  background: transparent;
  color: #1a1a1a;
  padding: 0.15rem 0.1rem 0.2rem;
  box-sizing: border-box;
}

.bdb-msg p {
  margin: 0 0 0.7rem;
  font-size: 0.98rem;
  font-weight: 600;
  min-height: 1.35em;
}

.bdb-msg p.is-typing::after,
.bdb-intro.is-typing::after {
  content: "";
  display: inline-block;
  width: 0.45em;
  height: 1em;
  margin-left: 0.12em;
  background: #cb3522;
  vertical-align: text-bottom;
  animation: bdb-caret 0.7s steps(1) infinite;
}

.bdb-choices {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

@keyframes bdb-in {
  from {
    opacity: 0;
    transform: translateY(7px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.bdb-msg:not(.is-instant) .bdb-chip,
.bdb-msg:not(.is-instant) .bdb-link,
.bdb-msg:not(.is-instant) .bdb-field,
.bdb-msg:not(.is-instant) .bdb-send {
  opacity: 0;
}

.bdb-msg:not(.is-instant) .bdb-chip.is-enter,
.bdb-msg:not(.is-instant) .bdb-link.is-enter,
.bdb-msg:not(.is-instant) .bdb-field.is-enter,
.bdb-msg:not(.is-instant) .bdb-send.is-enter {
  animation: bdb-in 0.42s ease forwards;
  animation-delay: var(--bdb-in-delay, 0ms);
}

@media (prefers-reduced-motion: reduce) {
  .bdb-msg:not(.is-instant) .bdb-chip,
  .bdb-msg:not(.is-instant) .bdb-link,
  .bdb-msg:not(.is-instant) .bdb-field,
  .bdb-msg:not(.is-instant) .bdb-send {
    opacity: 1;
    animation: none;
  }
}

.bdb-chip {
  appearance: none;
  border: 0;
  background: #8f8f8f;
  color: #fff;
  padding: 0.58rem 0.55rem;
  border-radius: 3px;
  font-size: 0.86rem;
  font-weight: 600;
  cursor: pointer;
  min-height: 2.45rem;
  white-space: nowrap;
}

.bdb-chip:hover,
.bdb-chip:focus,
.bdb-chip:focus-visible,
.bdb-chip:active,
.bdb-chip.is-selected {
  background: #cb3522 !important;
  background-color: #cb3522 !important;
  color: #fff !important;
  box-shadow: none !important;
}

.bdb-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.35rem;
  margin-top: 0.95rem;
}

.bdb-link {
  appearance: none;
  border: 0;
  background: transparent !important;
  background-color: transparent !important;
  color: #333;
  padding: 0.15rem 0;
  min-height: 0;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  box-shadow: none !important;
}

.bdb-link:hover,
.bdb-link:focus,
.bdb-link:focus-visible,
.bdb-link:active {
  background: transparent !important;
  background-color: transparent !important;
  color: var(--bdb-red) !important;
  box-shadow: none !important;
}

.bdb-form {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.5rem;
}

.bdb-field {
  width: min(17.5rem, 100%);
  max-width: 100%;
  box-sizing: border-box;
  border: 0 !important;
  outline: none !important;
  box-shadow: none !important;
  background: #fff;
  border-radius: 3px;
  padding: 0.7rem 0.8rem;
  font-size: 16px;
  color: #111;
}

.bdb-field:focus {
  outline: none !important;
  box-shadow: none !important;
  border: 0 !important;
}

.bdb-send {
  width: auto;
  min-width: 8.5rem;
  border: 0;
  font-weight: 700;
  font-size: 1rem;
  padding: 0.75rem 1.35rem;
  border-radius: 3px;
  cursor: pointer;
  margin-top: 0.2rem;
  background: #cb3522 !important;
  background-color: #cb3522 !important;
  color: #fff !important;
}

.bdb-send:hover,
.bdb-send:focus,
.bdb-send:focus-visible,
.bdb-send:active {
  background: #cb3522 !important;
  background-color: #cb3522 !important;
  color: #fff !important;
}

.bdb-send:disabled {
  opacity: 0.6;
  cursor: wait;
}

.bdb-error {
  color: var(--bdb-red);
  font-size: 0.88rem;
  margin: 0;
  font-weight: 500;
}

.bdb-done {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 600;
  color: #2e7d32;
}

.bdb-note {
  flex: 0 0 auto;
  margin: 0.95rem 0 0;
  font-family: "Segoe Script", "Bradley Hand", "Comic Sans MS", cursive;
  font-size: 1.05rem;
  color: #3a3a3a;
}

@keyframes bdb-caret {
  50% {
    opacity: 0;
  }
}

.elementor-popup-modal:has(.bdb-root) .elementor-shortcode,
.elementor-popup-modal:has(.bdb-root) .elementor-widget-container {
  width: 100% !important;
  max-width: 100% !important;
}

@media (min-width: 641px) {
  .bdb-choices {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 0.4rem;
  }

  .bdb-chip {
    width: 100%;
    min-width: 0;
    font-size: 0.8rem;
    padding: 0.52rem 0.2rem;
  }
}

@media (max-width: 640px) {
  .bdb-dialog {
    padding: 1.1rem 0.9rem 1rem;
  }

  .bdb-hero {
    padding-right: 2rem;
  }

  .bdb-hero h2 {
    font-size: 1.25rem;
  }

  .bdb-hero p,
  .bdb-msg p,
  .bdb-note {
    font-size: 0.92rem;
  }

  .bdb-chip {
    flex: 1 1 calc(50% - 0.45rem);
    font-size: 0.8rem;
    min-height: 2.6rem;
  }

  .bdb-field,
  .bdb-send {
    width: 100%;
    max-width: 100%;
  }
}
