.dt-brand-assistant-root {
  position: fixed;
  inset: 0;
  z-index: 999999;
  pointer-events: none;
  font-family: inherit;
}

.dt-brand-assistant-root.is-ready {
  display: block;
}

.dt-brand-assistant-fab {
  position: fixed;
  right: 24px;
  bottom: 24px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: none;
  border-radius: 999px;
  background: linear-gradient(135deg, #0d4c9c, #1f6ad1);
  color: #fff;
  padding: 14px 18px;
  box-shadow: 0 18px 38px rgba(13, 76, 156, 0.28);
  cursor: pointer;
  pointer-events: auto;
}

.dt-brand-assistant-root:not(.show-fab) .dt-brand-assistant-fab {
  display: none;
}

.dt-brand-assistant-overlay {
  position: fixed;
  inset: 0;
  background: rgba(9, 20, 41, 0.44);
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease;
  pointer-events: none;
}

.dt-brand-assistant-modal {
  position: fixed;
  right: 24px;
  bottom: 92px;
  width: min(440px, calc(100vw - 24px));
  max-height: calc(100vh - 120px);
  background: #fff;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(15, 23, 42, 0.22);
  transform: translateY(12px) scale(0.98);
  opacity: 0;
  visibility: hidden;
  transition: all 0.22s ease;
  display: flex;
  flex-direction: column;
  pointer-events: none;
}

.dt-brand-assistant-root.is-open .dt-brand-assistant-overlay,
.dt-brand-assistant-root.is-open .dt-brand-assistant-modal {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.dt-brand-assistant-root.is-open .dt-brand-assistant-modal {
  transform: translateY(0) scale(1);
}

.dt-brand-assistant-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px;
  color: #fff;
  background: linear-gradient(135deg, #0d4c9c, #1c66cb);
}

.dt-brand-assistant-kicker {
  margin: 0 0 4px;
  font-size: 12px;
  opacity: 0.85;
}

.dt-brand-assistant-header h3 {
  margin: 0;
  font-size: 22px;
  line-height: 1.2;
}

.dt-brand-assistant-close {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: none;
  background: rgba(255,255,255,0.16);
  color: #fff;
  font-size: 24px;
  cursor: pointer;
}

.dt-brand-assistant-product {
  padding: 16px 20px;
  background: #f7fbff;
  border-bottom: 1px solid #e4edf8;
}

.dt-brand-assistant-product-card {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 14px;
  align-items: center;
}

.dt-brand-assistant-product-card img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 16px;
  background: #fff;
  border: 1px solid #dce8f7;
}

.dt-brand-assistant-product-card h4 {
  margin: 0 0 8px;
  font-size: 16px;
  line-height: 1.35;
  color: #16345f;
}

.dt-brand-assistant-product-card p {
  margin: 0;
  font-size: 13px;
  color: #45658f;
}

.dt-brand-assistant-messages {
  padding: 16px 20px 8px;
  overflow: auto;
  max-height: 260px;
  background: #fff;
}

.dt-brand-assistant-message {
  margin-bottom: 12px;
  display: flex;
}

.dt-brand-assistant-message span {
  display: inline-block;
  max-width: 88%;
  padding: 12px 14px;
  border-radius: 18px;
  line-height: 1.5;
  font-size: 14px;
}

.dt-brand-assistant-message.is-bot span {
  background: #f3f7fd;
  color: #1b3558;
  border-top-left-radius: 6px;
}

.dt-brand-assistant-message.is-user {
  justify-content: flex-end;
}

.dt-brand-assistant-message.is-user span {
  background: #0d4c9c;
  color: #fff;
  border-top-right-radius: 6px;
}

.dt-brand-assistant-form {
  padding: 16px 20px 20px;
  border-top: 1px solid #edf2f8;
  background: #fff;
}

.dt-brand-assistant-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 10px;
}

.dt-brand-assistant-form input,
.dt-brand-assistant-form textarea {
  width: 100%;
  border: 1px solid #d7e3f2;
  border-radius: 14px;
  padding: 12px 14px;
  box-sizing: border-box;
  font: inherit;
  outline: none;
}

.dt-brand-assistant-form input:focus,
.dt-brand-assistant-form textarea:focus {
  border-color: #1c66cb;
  box-shadow: 0 0 0 3px rgba(28, 102, 203, 0.12);
}

.dt-brand-assistant-actions {
  margin-top: 12px;
  display: flex;
  justify-content: flex-end;
}

.dt-brand-assistant-submit {
  border: none;
  background: linear-gradient(135deg, #7ab73b, #8bcf3f);
  color: #fff;
  font-weight: 700;
  border-radius: 14px;
  padding: 12px 18px;
  cursor: pointer;
}

.dt-brand-assistant-submit[disabled] {
  opacity: 0.65;
  cursor: not-allowed;
}

.dt-brand-assistant-inline-trigger {
  position: relative;
}

.dt-brand-assistant-inline-trigger::after {
  content: ' AI';
  font-weight: 700;
}

@media (max-width: 640px) {
  .dt-brand-assistant-modal {
    right: 12px;
    left: 12px;
    width: auto;
    bottom: 12px;
    max-height: calc(100vh - 24px);
  }

  .dt-brand-assistant-fab {
    right: 12px;
    bottom: 12px;
  }

  .dt-brand-assistant-grid {
    grid-template-columns: 1fr;
  }
}
