/* ============================================================
   Quint — sheets.css (agente C: QuoteSheet + AssistSheet)
   Usa só tokens --q-* e as classes base .q-sheet* de brand.css.
   Transições 150ms, slide-in pela direita, full-screen no mobile.
   ============================================================ */

.q-sheet-overlay-wrap { position: fixed; inset: 0; z-index: 90; }

@keyframes q-sheet-in {
  from { transform: translateX(24px); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}
.q-sheet { animation: q-sheet-in 150ms cubic-bezier(.4, 0, .2, 1); }

/* Título do cabeçalho alinhado à identidade nova (espacejamento -0.5px) */
.q-sheet-header h3 { letter-spacing: -0.5px; }

/* ---------- QuoteSheet ---------- */
.q-quote-config-card {
  background: var(--q-bg-subtle);
  border: 1px solid var(--q-border);
  border-radius: var(--q-radius-ctl);
  padding: 16px;
  margin-bottom: 20px;
}
.q-quote-config-card .q-eyebrow { margin-bottom: 4px; }
.q-quote-config-card p { margin: 0; font: 500 14px/1.5 var(--q-font); color: var(--q-text); }

/* ---------- AssistSheet ---------- */
.q-sheet-assist .q-sheet-header { align-items: flex-start; }
.q-assist-sub { margin: 4px 0 0; font-size: 13px; color: var(--q-text-subtle); }

.q-assist-body { display: flex; flex-direction: column; gap: 14px; }

.q-assist-msg { display: flex; }
.q-assist-msg.is-user { justify-content: flex-end; }

.q-assist-bubble {
  max-width: 88%;
  padding: 10px 14px;
  border-radius: var(--q-radius-ctl);
  font-size: 14px;
  line-height: 1.5;
  white-space: pre-wrap;
  word-break: break-word;
}
.q-assist-msg.is-assistant .q-assist-bubble {
  background: var(--q-bg-subtle);
  color: var(--q-text);
  border: 1px solid var(--q-border);
}
.q-assist-msg.is-user .q-assist-bubble {
  background: var(--q-accent);
  color: var(--q-accent-fg);
}

.q-assist-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
/* Chips de fatos no estilo pill da identidade (eyebrow-pill-like, azul soft) */
.q-assist-chips .q-chip-soft { gap: 6px; }
.q-assist-chips .q-chip-soft::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: currentColor;
  flex: none;
}

.q-assist-suggestions { display: flex; flex-direction: column; gap: 12px; margin-top: 12px; }

.q-suggestion-card {
  display: flex;
  gap: 12px;
  border: 1px solid var(--q-border);
  border-radius: var(--q-radius);
  padding: 16px;
  background: var(--q-surface);
  transition: border-color 150ms, box-shadow 150ms;
}
.q-suggestion-card.is-recommended { border-color: var(--q-accent); box-shadow: var(--q-glow); }

.q-suggestion-num {
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: var(--q-accent);
  color: var(--q-accent-fg);
  font: 700 12px/24px var(--q-font);
  text-align: center;
}

.q-suggestion-body { flex: 1; min-width: 0; }
.q-suggestion-head { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; flex-wrap: wrap; }
.q-suggestion-head strong { font-size: 15px; color: var(--q-blue-900); }

.q-suggestion-list { margin: 0 0 12px; padding-left: 18px; font-size: 13px; color: var(--q-text-muted); }
.q-suggestion-list li { margin-bottom: 2px; }

.q-suggestion-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.q-suggestion-actions .q-btn { font-size: 13px; padding: 0.55rem 0.85rem; min-height: 36px; }

.q-assist-fallback { margin-top: 10px; }
.q-assist-fallback p { margin: 0 0 10px; font-size: 14px; color: var(--q-text-subtle); }

.q-assist-typing {
  display: flex;
  gap: 4px;
  padding: 10px 14px;
  width: fit-content;
  background: var(--q-bg-subtle);
  border: 1px solid var(--q-border);
  border-radius: var(--q-radius-ctl);
}
.q-assist-typing span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--q-text-subtle);
  animation: q-typing 1s infinite ease-in-out;
}
.q-assist-typing span:nth-child(2) { animation-delay: .15s; }
.q-assist-typing span:nth-child(3) { animation-delay: .3s; }
@keyframes q-typing {
  0%, 80%, 100% { transform: scale(.6); opacity: .4; }
  40% { transform: scale(1); opacity: 1; }
}

.q-assist-footer { display: flex; flex-direction: column; gap: 10px; }
.q-assist-quick { display: flex; justify-content: flex-end; }
.q-assist-form { display: flex; gap: 8px; }
.q-assist-form .q-input { flex: 1; }
.q-assist-form .q-btn { flex: 0 0 auto; }

/* ---------- Full-screen no mobile ---------- */
@media (max-width: 640px) {
  .q-sheet { width: 100vw; border-left: none; }
  .q-assist-bubble { max-width: 92%; }
}
