/* ═══════════════════════════════════════════════════════════════════════════
   RoosisIA Agent Core — Widget de Chat CSS
   Universal: funciona em qualquer site (WordPress ou externo)
   ═══════════════════════════════════════════════════════════════════════════ */

:root {
  --ri-w-accent:      #6366f1;
  --ri-w-accent-2:    #8b5cf6;
  --ri-w-bg:          #0f0f1a;
  --ri-w-surface:     #1a1a2e;
  --ri-w-border:      rgba(255,255,255,0.1);
  --ri-w-text:        #e2e8f0;
  --ri-w-text-muted:  #94a3b8;
  --ri-w-user-bg:     linear-gradient(135deg, #6366f1, #8b5cf6);
  --ri-w-ai-bg:       rgba(255,255,255,0.06);
  --ri-w-shadow:      0 20px 60px rgba(0,0,0,0.5), 0 0 0 1px rgba(255,255,255,0.05);
  --ri-w-radius:      20px;
  --ri-w-radius-msg:  16px;
  --ri-w-size:        380px;
}

/* ── Fab Button ───────────────────────────────────────────────────────────── */
#roosisia-fab {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--ri-w-accent), var(--ri-w-accent-2));
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  box-shadow: 0 8px 30px rgba(99,102,241,0.5);
  z-index: 999998;
  transition: all 0.3s cubic-bezier(0.34,1.56,0.64,1);
  animation: roosisia-pulse 2s ease-in-out infinite;
}

#roosisia-fab:hover {
  transform: scale(1.1);
  box-shadow: 0 12px 40px rgba(99,102,241,0.7);
}

#roosisia-fab.open {
  transform: rotate(45deg) scale(1.05);
  animation: none;
}

@keyframes roosisia-pulse {
  0%, 100% { box-shadow: 0 8px 30px rgba(99,102,241,0.5); }
  50%       { box-shadow: 0 8px 50px rgba(99,102,241,0.8); }
}

#roosisia-fab-icon-open,
#roosisia-fab-icon-close { transition: all 0.3s ease; }
#roosisia-fab.open #roosisia-fab-icon-open  { display: none; }
#roosisia-fab.open #roosisia-fab-icon-close { display: flex; }
#roosisia-fab:not(.open) #roosisia-fab-icon-close { display: none; }

#roosisia-widget {
  position: fixed;
  bottom: 100px;
  right: 24px;
  width: var(--ri-w-size);
  max-height: 620px;
  background: var(--ri-w-bg);
  border: 1px solid var(--ri-w-border);
  border-radius: var(--ri-w-radius);
  box-shadow: var(--ri-w-shadow);
  z-index: 999997;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: scale(0.9) translateY(20px);
  opacity: 0;
  pointer-events: none !important;
  transition: transform 0.35s cubic-bezier(0.34,1.56,0.64,1), opacity 0.35s ease;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  isolation: isolate;
}

#roosisia-widget.open {
  transform: scale(1) translateY(0);
  opacity: 1;
  pointer-events: auto !important;
}

/* ── Widget Header ────────────────────────────────────────────────────────── */
.ri-w-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  background: linear-gradient(135deg, var(--ri-w-accent), var(--ri-w-accent-2));
  position: relative;
  overflow: hidden;
}

.ri-w-header::after {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Ccircle cx='30' cy='30' r='20'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

.ri-w-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
}

.ri-w-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

#roosisia-fab-icon-open img,
#roosisia-flow-fab-icon-open img {
  width: 36px;
  height: 36px;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

.ri-w-online-dot {
  position: absolute;
  bottom: 0; right: 0;
  width: 10px; height: 10px;
  background: #10b981;
  border: 2px solid #6366f1;
  border-radius: 50%;
}

.ri-w-agent-info { flex: 1; }

.ri-w-agent-name {
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  margin: 0 0 2px;
  font-family: 'Inter', sans-serif;
}

.ri-w-status {
  font-size: 12px;
  color: rgba(255,255,255,0.7);
  display: flex;
  align-items: center;
  gap: 4px;
}

.ri-w-close-btn {
  background: rgba(255,255,255,0.15);
  border: none;
  border-radius: 8px;
  width: 32px; height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #fff;
  font-size: 16px;
  transition: background 0.2s;
}
.ri-w-close-btn:hover { background: rgba(255,255,255,0.25); }

/* ── Messages Area ────────────────────────────────────────────────────────── */
.ri-w-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  scroll-behavior: smooth;
}

.ri-w-messages::-webkit-scrollbar { width: 4px; }
.ri-w-messages::-webkit-scrollbar-track { background: transparent; }
.ri-w-messages::-webkit-scrollbar-thumb { background: var(--ri-w-border); border-radius: 2px; }

/* ── Message Bubbles ──────────────────────────────────────────────────────── */
.ri-w-msg {
  display: flex;
  gap: 8px;
  max-width: 85%;
  animation: roosisia-msg-in 0.3s ease;
}

@keyframes roosisia-msg-in {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.ri-w-msg.user { align-self: flex-end; flex-direction: row-reverse; }
.ri-w-msg.ai   { align-self: flex-start; }

.ri-w-bubble {
  padding: 10px 14px;
  border-radius: var(--ri-w-radius-msg);
  font-size: 14px;
  line-height: 1.5;
  font-family: 'Inter', sans-serif;
}

.ri-w-msg.user  .ri-w-bubble {
  background: var(--ri-w-user-bg);
  color: #fff;
  border-bottom-right-radius: 4px;
}

.ri-w-msg.ai .ri-w-bubble {
  background: var(--ri-w-ai-bg);
  border: 1px solid var(--ri-w-border);
  color: var(--ri-w-text);
  border-bottom-left-radius: 4px;
}

.ri-w-msg-time {
  font-size: 10px;
  color: var(--ri-w-text-muted);
  margin-top: 4px;
  align-self: flex-end;
}

/* ── Typing indicator ─────────────────────────────────────────────────────── */
.ri-w-typing {
  display: flex;
  gap: 4px;
  padding: 12px 16px;
  background: var(--ri-w-ai-bg);
  border: 1px solid var(--ri-w-border);
  border-radius: var(--ri-w-radius-msg);
  border-bottom-left-radius: 4px;
  align-self: flex-start;
  width: fit-content;
}

.ri-w-typing span {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--ri-w-text-muted);
  animation: roosisia-typing 1.2s ease-in-out infinite;
}

.ri-w-typing span:nth-child(2) { animation-delay: 0.2s; }
.ri-w-typing span:nth-child(3) { animation-delay: 0.4s; }

@keyframes roosisia-typing {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
  30%            { transform: translateY(-5px); opacity: 1; }
}

/* ── Budget Card ──────────────────────────────────────────────────────────── */
.ri-w-budget-card {
  background: linear-gradient(135deg, rgba(99,102,241,0.15), rgba(139,92,246,0.1));
  border: 1px solid rgba(99,102,241,0.3);
  border-radius: 14px;
  padding: 16px;
  margin-top: 8px;
  font-family: 'Inter', sans-serif;
}

.ri-w-budget-title {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #818cf8;
  font-weight: 600;
  margin-bottom: 10px;
}

.ri-w-budget-total {
  font-size: 24px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 12px;
}

.ri-w-budget-actions {
  display: flex;
  gap: 8px;
}

.ri-w-btn-wa {
  flex: 1;
  background: #25d366;
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 10px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-decoration: none;
  transition: background 0.2s, transform 0.2s;
}
.ri-w-btn-wa:hover { background: #1da851; transform: scale(1.02); }

/* ── Rich Components Cards ─────────────────────────────────────────────── */
.ri-w-rich-card {
  background: linear-gradient(135deg, rgba(99,102,241,0.15), rgba(139,92,246,0.1));
  border: 1px solid rgba(99,102,241,0.3);
  border-radius: 14px;
  padding: 16px;
  width: 100%;
  font-family: 'Inter', sans-serif;
  box-sizing: border-box;
}

.ri-w-card-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.ri-w-card-icon {
  font-size: 20px;
}

.ri-w-card-title {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
}

.ri-w-card-sub {
  font-size: 12px;
  color: var(--ri-w-text-muted);
}

.ri-w-card-amount {
  font-size: 22px;
  font-weight: 800;
  color: #10b981;
  margin: 6px 0;
}

.ri-w-card-badge {
  font-size: 12px;
  color: #10b981;
  background: rgba(16,185,129,0.15);
  padding: 4px 8px;
  border-radius: 6px;
  display: inline-block;
  margin-bottom: 6px;
}

.ri-w-card-meta {
  font-size: 11px;
  color: var(--ri-w-text-muted);
  margin-bottom: 12px;
}

.ri-w-card-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ri-w-btn {
  border: none;
  border-radius: 10px;
  padding: 9px 12px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-decoration: none;
  transition: all 0.2s;
}

.ri-w-btn-emerald { background: #10b981; color: #fff; }
.ri-w-btn-emerald:hover { background: #059669; }

.ri-w-btn-indigo { background: #6366f1; color: #fff; }
.ri-w-btn-indigo:hover { background: #4f46e5; }

.ri-w-btn-green { background: #25d366; color: #fff; }
.ri-w-btn-green:hover { background: #1da851; }

.ri-w-pix-input-wrap {
  display: flex;
  gap: 6px;
  margin: 10px 0;
}

.ri-w-pix-input {
  flex: 1;
  background: var(--ri-w-surface);
  border: 1px solid var(--ri-w-border);
  border-radius: 8px;
  color: var(--ri-w-text);
  padding: 6px 10px;
  font-size: 11px;
  font-family: monospace;
}

.ri-w-status-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #f59e0b;
  margin-top: 6px;
}

.ri-w-pulse-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #f59e0b;
  animation: roosisia-pulse 1.5s infinite;
}

.ri-w-tiers-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 10px;
}

.ri-w-btn-tier {
  background: var(--ri-w-surface);
  border: 1px solid var(--ri-w-border);
  color: var(--ri-w-text);
  padding: 10px 6px;
  font-size: 13px;
  font-weight: 700;
}
.ri-w-btn-tier:hover {
  border-color: var(--ri-w-accent);
  background: rgba(99,102,241,0.2);
  color: #fff;
}

/* ── Input Area ───────────────────────────────────────────────────────────── */
.ri-w-input-area {
  padding: 12px 16px;
  border-top: 1px solid var(--ri-w-border);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ri-w-input-row {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  background: var(--ri-w-surface);
  border: 1px solid var(--ri-w-border);
  border-radius: 14px;
  padding: 6px 8px 6px 14px;
  transition: border-color 0.2s;
}

.ri-w-input-row:focus-within { border-color: var(--ri-w-accent); }

#roosisia-input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  color: var(--ri-w-text);
  font-size: 14px;
  font-family: 'Inter', sans-serif;
  resize: none;
  max-height: 100px;
  line-height: 1.4;
  padding: 4px 0;
}

#roosisia-input::placeholder { color: var(--ri-w-text-muted); }

.ri-w-send-btn {
  width: 42px;
  height: 42px;
  min-width: 42px;
  min-height: 42px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--ri-w-accent), var(--ri-w-accent-2));
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  flex-shrink: 0;
  transition: transform 0.2s, box-shadow 0.2s;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
.ri-w-send-btn:hover:not(:disabled) {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(99,102,241,0.5);
}
.ri-w-send-btn:disabled { opacity: 0.4; cursor: not-allowed; }

/* ── Flow FAB Button (Esquerda) ────────────────────────────────────────────── */
#roosisia-flow-fab {
  position: fixed;
  bottom: 24px;
  left: 24px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: linear-gradient(135deg, #10b981, #059669);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  box-shadow: 0 8px 30px rgba(16,185,129,0.5);
  z-index: 999998;
  transition: transform 0.3s cubic-bezier(0.34,1.56,0.64,1), box-shadow 0.3s ease;
  animation: roosisia-flow-pulse 2s ease-in-out infinite;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

#roosisia-flow-fab:hover {
  transform: scale(1.1);
  box-shadow: 0 12px 40px rgba(16,185,129,0.7);
}

#roosisia-flow-fab.open {
  transform: rotate(45deg) scale(1.05);
  animation: none;
}

@keyframes roosisia-flow-pulse {
  0%, 100% { box-shadow: 0 8px 30px rgba(16,185,129,0.5); }
  50%       { box-shadow: 0 8px 50px rgba(16,185,129,0.8); }
}

#roosisia-flow-fab-icon-open,
#roosisia-flow-fab-icon-close { transition: all 0.3s ease; }
#roosisia-flow-fab.open #roosisia-flow-fab-icon-open  { display: none; }
#roosisia-flow-fab.open #roosisia-flow-fab-icon-close { display: flex; }
#roosisia-flow-fab:not(.open) #roosisia-flow-fab-icon-close { display: none; }

/* ── Flow Widget Window (Esquerda) ────────────────────────────────────────── */
#roosisia-flow-widget {
  position: fixed;
  bottom: 100px;
  left: 24px;
  width: var(--ri-w-size);
  max-height: 620px;
  background: var(--ri-w-bg);
  border: 1px solid var(--ri-w-border);
  border-radius: var(--ri-w-radius);
  box-shadow: var(--ri-w-shadow);
  z-index: 999997;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: scale(0.9) translateY(20px);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.35s cubic-bezier(0.34,1.56,0.64,1), opacity 0.35s ease;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  isolation: isolate;
}

#roosisia-flow-widget.open {
  transform: scale(1) translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.ri-w-flow-header {
  background: linear-gradient(135deg, #10b981, #059669) !important;
}

/* ── Flow Options Area ────────────────────────────────────────────────────── */
.ri-w-flow-options-area {
  padding: 12px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-top: 1px solid var(--ri-w-border);
  max-height: 200px;
  overflow-y: auto;
  background: var(--ri-w-surface);
}

.ri-w-flow-btn {
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--ri-w-border);
  border-radius: 12px;
  color: #fff;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  text-decoration: none;
  transition: all 0.2s ease;
  touch-action: manipulation;
  min-height: 42px;
  box-sizing: border-box;
}

.ri-w-flow-btn:hover {
  background: rgba(16,185,129,0.15);
  border-color: #10b981;
  transform: translateY(-1px);
}

.ri-w-flow-btn .ri-w-flow-arrow {
  color: #10b981;
  font-size: 14px;
  margin-left: 8px;
}

/* ── Callout Bubbles Flutuantes ───────────────────────────────────────────── */
.ri-w-callout-bubble {
  position: fixed;
  bottom: 94px;
  max-width: 260px;
  background: var(--ri-w-surface);
  border: 1px solid var(--ri-w-border);
  color: var(--ri-w-text);
  padding: 10px 32px 10px 14px;
  border-radius: 14px;
  font-size: 13px;
  line-height: 1.4;
  box-shadow: 0 10px 30px rgba(0,0,0,0.4);
  z-index: 999996;
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  display: flex;
  align-items: center;
}

.ri-w-callout-bubble.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.ri-w-callout-right {
  right: 24px;
}

.ri-w-callout-right::after {
  content: '';
  position: absolute;
  bottom: -6px;
  right: 24px;
  width: 12px;
  height: 12px;
  background: var(--ri-w-surface);
  border-right: 1px solid var(--ri-w-border);
  border-bottom: 1px solid var(--ri-w-border);
  transform: rotate(45deg);
}

.ri-w-callout-left {
  left: 24px;
}

.ri-w-callout-left::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 24px;
  width: 12px;
  height: 12px;
  background: var(--ri-w-surface);
  border-right: 1px solid var(--ri-w-border);
  border-bottom: 1px solid var(--ri-w-border);
  transform: rotate(45deg);
}

.ri-w-bubble-close {
  position: absolute;
  top: 6px;
  right: 6px;
  background: none;
  border: none;
  color: var(--ri-w-text-muted);
  cursor: pointer;
  font-size: 12px;
  padding: 2px 4px;
}
.ri-w-bubble-close:hover { color: #fff; }

.ri-w-footer {
  text-align: center;
  font-size: 11px;
  color: var(--ri-w-text-muted);
  font-family: 'Inter', sans-serif;
}

.ri-w-footer a {
  color: var(--ri-w-accent);
  text-decoration: none;
}

/* ── Responsive ───────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  #roosisia-widget,
  #roosisia-flow-widget {
    right: 0 !important;
    left: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    height: 100vh !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    border-radius: var(--ri-w-radius) var(--ri-w-radius) 0 0 !important;
  }
  #roosisia-fab { bottom: 80px; right: 16px; }
  #roosisia-flow-fab { bottom: 80px; left: 16px; }
  .ri-w-callout-right { bottom: 150px; right: 16px; }
  .ri-w-callout-left { bottom: 150px; left: 16px; }
}

/* ── Quantum Quick Chips (Pílulas de Ação Rápida) ─────────────────────────── */
.ri-w-chips-container {
  display: flex;
  flex-wrap: nowrap;
  overflow-x: auto;
  gap: 8px;
  padding: 8px 12px;
  background: rgba(10, 15, 30, 0.85);
  border-top: 1px solid rgba(0, 240, 255, 0.18);
  transition: all 0.3s ease;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 240, 255, 0.3) transparent;
}

.ri-w-chips-container::-webkit-scrollbar {
  height: 3px;
}
.ri-w-chips-container::-webkit-scrollbar-track {
  background: transparent;
}
.ri-w-chips-container::-webkit-scrollbar-thumb {
  background: rgba(0, 240, 255, 0.3);
  border-radius: 3px;
}

.ri-w-chip {
  flex-shrink: 0;
  white-space: nowrap;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(0, 240, 255, 0.3);
  color: #c7d2fe;
  padding: 6px 12px;
  border-radius: 16px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  user-select: none;
}

.ri-w-chip:hover {
  background: rgba(0, 240, 255, 0.2);
  border-color: #00f0ff;
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 2px 10px rgba(0, 240, 255, 0.3);
}

.ri-w-chip:active {
  transform: translateY(0);
}

/* ── Botões Interativos Clicáveis no Corpo da Mensagem (Links & Ações) ───── */
.ri-w-interactive-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, rgba(0, 240, 255, 0.16), rgba(99, 102, 241, 0.28));
  border: 1px solid rgba(0, 240, 255, 0.5);
  color: #00f0ff !important;
  text-decoration: none !important;
  font-size: 12px;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 20px;
  margin: 6px 2px;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 2px 8px rgba(0, 240, 255, 0.15);
  cursor: pointer;
  vertical-align: middle;
}

.ri-w-interactive-btn:hover {
  background: linear-gradient(135deg, rgba(0, 240, 255, 0.35), rgba(99, 102, 241, 0.5));
  border-color: #00f0ff;
  color: #ffffff !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(0, 240, 255, 0.45);
}

.ri-w-interactive-btn .ri-w-btn-icon {
  font-size: 13px;
}

.ri-w-interactive-btn .ri-w-btn-arrow {
  font-size: 11px;
  transition: transform 0.2s ease;
}

.ri-w-interactive-btn:hover .ri-w-btn-arrow {
  transform: translateX(3px);
}

/* ── Quantum Tone Buttons & Inline Actions ──────────────────────────────── */
.ri-w-tone-btn, .ri-w-breath-btn {
  background: rgba(0, 240, 255, 0.12);
  border: 1px solid rgba(0, 240, 255, 0.4);
  color: #00f0ff;
  border-radius: 20px;
  padding: 6px 12px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.ri-w-tone-btn:hover, .ri-w-breath-btn:hover {
  background: rgba(0, 240, 255, 0.25);
  border-color: #00f0ff;
  transform: translateY(-1px);
  box-shadow: 0 0 12px rgba(0, 240, 255, 0.35);
}
.ri-w-tone-btn.is-playing {
  background: #10b981 !important;
  color: #090d16 !important;
  border-color: #10b981 !important;
  animation: riPulseTone 1.5s infinite;
}
@keyframes riPulseTone {
  0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.6); }
  70% { box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
  100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

/* ── Avatar Cymatics / Espectro Harmônico ────────────────────────────────── */
.ri-w-avatar.ri-avatar-harmonic {
  position: relative;
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.8);
  animation: riHarmonicGlow 2s infinite alternate;
}
.ri-w-avatar.ri-avatar-harmonic::after {
  content: '';
  position: absolute;
  top: -4px;
  left: -4px;
  right: -4px;
  bottom: -4px;
  border-radius: 50%;
  border: 2px solid #00f0ff;
  animation: riCymaticsRings 1.8s infinite ease-out;
  pointer-events: none;
}
@keyframes riHarmonicGlow {
  0% { filter: drop-shadow(0 0 2px #00f0ff); }
  100% { filter: drop-shadow(0 0 10px #8b5cf6); }
}
@keyframes riCymaticsRings {
  0% { transform: scale(0.9); opacity: 0.9; }
  100% { transform: scale(1.5); opacity: 0; }
}

/* ── Pacer Respiratório 5s/5s ────────────────────────────────────────────── */
.ri-w-pacer-card {
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.95), rgba(9, 13, 22, 0.98));
  border: 1px solid rgba(0, 240, 255, 0.35);
  border-radius: 16px;
  padding: 16px;
  margin: 10px 0;
  box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}
.ri-w-pacer-circle-wrap {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 140px;
}
.ri-w-pacer-circle {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: radial-gradient(circle, #00f0ff 0%, #1e1b4b 70%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #fff;
  transition: all 5s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.3);
}
.ri-w-pacer-circle.is-inhaling {
  transform: scale(1.6);
  background: radial-gradient(circle, #00f0ff 20%, #10b981 80%);
  box-shadow: 0 0 35px rgba(0, 240, 255, 0.7);
}
.ri-w-pacer-circle.is-exhaling {
  transform: scale(0.85);
  background: radial-gradient(circle, #8b5cf6 20%, #1e1b4b 80%);
  box-shadow: 0 0 15px rgba(139, 92, 246, 0.4);
}
.ri-w-pacer-text {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.ri-w-pacer-timer {
  font-size: 16px;
  font-weight: 800;
}
