.vca-assistant-launch {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.35rem;
  min-height: 2.5rem;
  max-width: 7.5rem;
  margin-left: 0.35rem;
  padding: 0.25rem 0.55rem 0.25rem 0.4rem;
  border: 1px solid #a7f3d0;
  border-radius: 0.65rem;
  background: linear-gradient(180deg, #ecfdf5 0%, #fff 100%);
  color: #047857;
  cursor: pointer;
  vertical-align: middle;
  flex-shrink: 0;
  line-height: 1.05;
  box-shadow: 0 1px 3px rgba(4, 120, 87, 0.12);
}

.vca-assistant-launch:hover {
  background: #d1fae5;
  border-color: #059669;
}

.vca-launch-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 0.45rem;
  background: #059669;
  color: #fff;
  flex-shrink: 0;
}

.vca-launch-label {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
}

.vca-launch-line {
  display: block;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: #065f46;
  white-space: nowrap;
}

.vca-svg {
  display: block;
}

.vca-assistant-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: flex;
  flex-direction: column;
  background: #fafafa;
  color: #18181b;
}

.vca-assistant-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #e4e4e7;
  background: #fff;
}

.vca-assistant-title {
  text-align: center;
  font-size: 0.875rem;
  font-weight: 700;
}

.vca-assistant-sub {
  font-size: 0.75rem;
  color: #71717a;
  font-weight: 400;
}

.vca-assistant-body {
  display: flex;
  flex: 1;
  min-height: 0;
  flex-direction: column;
}

@media (min-width: 1024px) {
  .vca-assistant-body {
    flex-direction: row;
  }
}

.vca-assistant-chat {
  display: flex;
  flex-direction: column;
  min-height: 0;
  border-bottom: 1px solid #e4e4e7;
  background: #fff;
}

@media (min-width: 1024px) {
  .vca-assistant-chat {
    width: 33.333%;
    border-bottom: 0;
    border-right: 1px solid #e4e4e7;
  }
}

.vca-assistant-messages {
  flex: 1;
  min-height: 8rem;
  overflow-y: auto;
  margin: 0.75rem 1rem;
  padding: 0.5rem 0.75rem;
  border: 1px solid #e4e4e7;
  border-radius: 0.75rem;
  background: #fafafa;
  display: flex;
  flex-direction: column;
}

.vca-assistant-msg {
  max-width: 95%;
  margin-bottom: 0.5rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  line-height: 1.35;
  border-radius: 0.75rem;
}

.vca-assistant-msg--bot {
  align-self: flex-start;
  background: #fff;
  box-shadow: 0 0 0 1px #e4e4e7;
}

.vca-assistant-msg--user {
  margin-left: auto;
  background: #059669;
  color: #fff;
}

.vca-assistant-composer {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0 1rem 0.35rem;
}

.vca-assistant-input {
  flex: 1;
  min-width: 0;
  padding: 0.55rem 0.75rem;
  font-size: 0.875rem;
  border: 1px solid #d4d4d8;
  border-radius: 0.65rem;
  background: #fff;
  color: #18181b;
}

.vca-assistant-input:focus {
  outline: none;
  border-color: #059669;
  box-shadow: 0 0 0 2px rgba(5, 150, 105, 0.2);
}

.vca-assistant-input:disabled {
  background: #f4f4f5;
  opacity: 0.85;
}

.vca-assistant-status {
  min-height: 1.1rem;
  margin: 0 1rem 0.75rem;
  font-size: 0.75rem;
  color: #71717a;
  text-align: center;
}

.vca-assistant-mic,
.vca-assistant-send {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 2.75rem !important;
  height: 2.75rem !important;
  min-width: 2.75rem !important;
  min-height: 2.75rem !important;
  flex-shrink: 0;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 9999px !important;
  cursor: pointer;
  overflow: visible !important;
  line-height: 1 !important;
  font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif !important;
}

.vca-assistant-mic {
  background: #059669 !important;
  color: #fff !important;
  box-shadow: 0 2px 8px rgba(5, 150, 105, 0.35);
}

.vca-assistant-send {
  background: #18181b !important;
  color: #fff !important;
}

.vca-btn-glyph {
  display: block !important;
  font-size: 1.35rem !important;
  line-height: 1 !important;
  pointer-events: none;
  color: inherit !important;
  opacity: 1 !important;
  visibility: visible !important;
}

.vca-btn-glyph--send {
  font-size: 1.2rem !important;
  font-weight: 700;
  transform: translateX(1px);
}

.vca-assistant-mic:hover:not(:disabled) {
  background: #047857;
}

.vca-assistant-send:hover:not(:disabled) {
  background: #27272a;
}

.vca-assistant-mic:disabled,
.vca-assistant-send:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.vca-assistant-mic.is-listening {
  background: #ef4444;
  animation: vca-pulse 1s infinite;
}

@keyframes vca-pulse {
  50% { opacity: 0.85; }
}

.vca-assistant-products {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 1rem;
  background: rgba(244, 244, 245, 0.8);
}

@media (min-width: 1024px) {
  .vca-assistant-products {
    width: 66.666%;
  }
}

.vca-assistant-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

@media (min-width: 640px) {
  .vca-assistant-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.vca-assistant-card {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  background: #fff;
  border-radius: 0.75rem;
  padding: 0.5rem;
  border: 1px solid #e4e4e7;
}

.vca-assistant-card img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: contain;
  border-radius: 0.5rem;
  background: #f4f4f5;
}

.vca-assistant-card h3 {
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.25;
  margin: 0;
}

.vca-assistant-card .price {
  font-size: 0.75rem;
  line-height: 1.3;
}

.vca-assistant-card .price .screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  width: 1px;
  word-wrap: normal !important;
}

.vca-assistant-card .price del {
  color: #71717a;
  font-weight: 400;
  opacity: 0.85;
}

.vca-assistant-card .price ins {
  color: #047857;
  font-weight: 600;
  text-decoration: none;
}

.vca-assistant-card .price > .woocommerce-Price-amount,
.vca-assistant-card .price ins .woocommerce-Price-amount {
  color: #047857;
  font-weight: 600;
}

.vca-assistant-card-actions {
  display: flex;
  gap: 0.35rem;
}

.vca-assistant-card-actions button,
.vca-assistant-card-actions a {
  flex: 1;
  font-size: 0.65rem;
  font-weight: 600;
  padding: 0.35rem 0.25rem;
  border-radius: 0.5rem;
  text-align: center;
  text-decoration: none;
  border: 1px solid #d4d4d8;
  background: #fff;
  cursor: pointer;
  color: inherit;
}

.vca-assistant-card-actions .primary {
  background: #059669;
  color: #fff;
  border-color: #059669;
}

.vca-assistant-empty {
  text-align: center;
  font-size: 0.875rem;
  color: #71717a;
  padding: 2rem 1rem;
}

.vca-assistant-btn {
  border: 1px solid #e4e4e7;
  border-radius: 0.5rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  background: #fff;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}

.vca-assistant-btn:hover {
  background: #f4f4f5;
}

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

/* Компактна кнопка в мобільній шапці */
.vca-assistant-launch--compact {
  max-width: 2.75rem;
  min-height: 2.25rem;
  padding: 0.2rem;
}

.vca-assistant-launch--compact .vca-launch-label {
  display: none;
}

.vca-assistant-launch--compact .vca-launch-icon {
  width: 2rem;
  height: 2rem;
}

/* Плаваюча кнопка на мобільному */
@media (max-width: 921px) {
  .vca-mobile-fab {
    position: fixed !important;
    right: 0.85rem !important;
    bottom: calc(0.85rem + env(safe-area-inset-bottom, 0px)) !important;
    z-index: 99998 !important;
    margin: 0 !important;
    max-width: none !important;
    min-height: 3rem !important;
    padding: 0.45rem 0.85rem 0.45rem 0.5rem !important;
    border-radius: 9999px !important;
    box-shadow: 0 4px 16px rgba(4, 120, 87, 0.35) !important;
  }

  .vca-mobile-fab .vca-launch-label {
    display: flex !important;
  }

  .vca-mobile-fab .vca-launch-line {
    font-size: 0.68rem !important;
  }

  .vca-assistant-overlay .vca-assistant-body {
    flex-direction: column;
  }

  .vca-assistant-chat {
    width: 100% !important;
    max-height: 45vh;
  }

  .vca-assistant-products {
    width: 100% !important;
    flex: 1;
  }

  .vca-assistant-composer {
    padding-bottom: calc(0.5rem + env(safe-area-inset-bottom, 0px));
  }
}
