/* Asistente IA — widget flotante. Colores por marca vía variables inline (WAC.accent). */
#wac-root, #wac-root * { box-sizing: border-box; }
#wac-root {
	--wac-accent: #C4622D;
	--wac-ink: #5C3D2E;
	--wac-bubble: #F2EDE8;
	font-family: "Hanken Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* Lanzador */
.wac-launcher {
	position: fixed; right: 20px; bottom: 20px; z-index: 99998;
	display: flex; align-items: center; gap: 8px;
	background: var(--wac-accent); color: #fff;
	border: none; border-radius: 999px; cursor: pointer;
	padding: 12px 18px; font-size: 15px; font-weight: 600;
	box-shadow: 0 8px 24px rgba(0,0,0,.18);
	transition: transform .15s ease, box-shadow .15s ease;
}
.wac-launcher:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(0,0,0,.22); }
.wac-launcher svg { width: 22px; height: 22px; }
.wac-launcher.wac-hidden { display: none; }

/* Panel */
.wac-panel {
	position: fixed; right: 20px; bottom: 20px; z-index: 99999;
	width: 380px; max-width: calc(100vw - 24px);
	height: 620px; max-height: calc(100vh - 40px);
	background: #fff; border-radius: 18px; overflow: hidden;
	display: none; flex-direction: column;
	box-shadow: 0 20px 60px rgba(0,0,0,.28);
	animation: wac-in .18s ease;
}
.wac-panel.wac-open { display: flex; }
@keyframes wac-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

.wac-head {
	background: var(--wac-accent); color: #fff;
	padding: 14px 16px; display: flex; align-items: center; justify-content: space-between;
}
.wac-head .wac-title { font-weight: 700; font-size: 16px; display: flex; align-items: center; gap: 8px; }
.wac-head .wac-dot { width: 8px; height: 8px; border-radius: 50%; background: #7fe08a; box-shadow: 0 0 0 3px rgba(127,224,138,.3); }
.wac-close { background: transparent; border: none; color: #fff; cursor: pointer; font-size: 22px; line-height: 1; opacity: .9; }
.wac-close:hover { opacity: 1; }

.wac-body { flex: 1; overflow-y: auto; padding: 16px; background: #fdfbf9; scroll-behavior: smooth; }

/* Mensajes */
.wac-msg { display: flex; margin-bottom: 12px; }
.wac-msg.wac-user { justify-content: flex-end; }
.wac-bubble {
	max-width: 82%; padding: 10px 14px; border-radius: 14px;
	font-size: 14.5px; line-height: 1.45; white-space: pre-wrap; word-wrap: break-word;
}
.wac-bot .wac-bubble { background: var(--wac-bubble); color: var(--wac-ink); border-bottom-left-radius: 4px; }
.wac-user .wac-bubble { background: var(--wac-accent); color: #fff; border-bottom-right-radius: 4px; }

/* Tarjetas de producto */
.wac-cards { display: flex; flex-direction: column; gap: 10px; margin: 4px 0 14px; }
.wac-card {
	display: flex; gap: 12px; background: #fff; border: 1px solid #E7DECF;
	border-radius: 14px; padding: 10px; align-items: center;
}
.wac-card img { width: 64px; height: 64px; object-fit: cover; border-radius: 10px; flex-shrink: 0; background: #f2ede8; }
.wac-card-info { flex: 1; min-width: 0; }
.wac-card-name { font-weight: 600; font-size: 14px; color: var(--wac-ink); margin: 0 0 2px; line-height: 1.3; }
.wac-card-name a { color: inherit; text-decoration: none; }
.wac-card-name a:hover { text-decoration: underline; }
.wac-card-price { font-size: 14px; font-weight: 700; color: var(--wac-accent); }
.wac-card-oos { font-size: 12px; color: #a33; }
.wac-card-actions { display: flex; flex-direction: column; gap: 6px; }
.wac-btn {
	border: none; border-radius: 999px; cursor: pointer; font-weight: 600;
	font-size: 12.5px; padding: 7px 12px; white-space: nowrap;
}
.wac-btn-add { background: var(--wac-accent); color: #fff; }
.wac-btn-add:hover { filter: brightness(.94); }
.wac-btn-add:disabled { opacity: .5; cursor: default; }
.wac-btn-view { background: #fff; color: var(--wac-ink); border: 1px solid #E7DECF; text-decoration: none; text-align: center; }

/* Escribiendo */
.wac-typing span { display: inline-block; width: 7px; height: 7px; margin: 0 1px; border-radius: 50%; background: #bbb; animation: wac-bounce 1.2s infinite; }
.wac-typing span:nth-child(2) { animation-delay: .2s; }
.wac-typing span:nth-child(3) { animation-delay: .4s; }
@keyframes wac-bounce { 0%,60%,100% { transform: translateY(0); opacity: .4; } 30% { transform: translateY(-5px); opacity: 1; } }

/* Sugerencias */
.wac-suggests { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.wac-chip {
	background: #fff; border: 1px solid var(--wac-accent); color: var(--wac-accent);
	border-radius: 999px; padding: 6px 12px; font-size: 12.5px; cursor: pointer;
}
.wac-chip:hover { background: var(--wac-accent); color: #fff; }

/* Input */
.wac-foot { border-top: 1px solid #eee4d8; padding: 10px; display: flex; gap: 8px; background: #fff; }
.wac-input {
	flex: 1; border: 1px solid #E7DECF; border-radius: 999px; padding: 10px 14px;
	font-size: 14px; resize: none; outline: none; max-height: 90px; font-family: inherit;
}
.wac-input:focus { border-color: var(--wac-accent); }
.wac-send { background: var(--wac-accent); color: #fff; border: none; border-radius: 50%; width: 40px; height: 40px; cursor: pointer; flex-shrink: 0; display: flex; align-items: center; justify-content: center; }
.wac-send:disabled { opacity: .5; cursor: default; }
.wac-send svg { width: 18px; height: 18px; }
.wac-note { text-align: center; font-size: 11px; color: #b0a595; padding: 4px 0 8px; }

@media (max-width: 480px) {
	.wac-panel { right: 0; bottom: 0; width: 100vw; height: 100vh; max-height: 100vh; border-radius: 0; }
}

/* Club — pill de estado */
.wac-club-pill {
	display: inline-flex; align-items: center; gap: 6px;
	border-radius: 999px; padding: 6px 14px; font-size: 13px; font-weight: 600;
	text-decoration: none; border: 1px solid var(--wac-accent, #C4622D);
}
.wac-club-pill--free { color: var(--wac-accent, #C4622D); background: transparent; }
.wac-club-pill--club { color: #fff; background: var(--wac-accent, #C4622D); }
.wac-club-pill--guest { color: #fff; background: var(--wac-accent, #C4622D); }
.wac-club-pill--guest:hover { opacity: .9; }

/* Club — formulario de ficha de mascota */
.wac-pet-form { max-width: 480px; display: flex; flex-direction: column; gap: 14px; margin-top: 12px; }
.wac-pet-form .wac-club-status { margin: 0 0 6px; }
.wac-pet-field { display: flex; flex-direction: column; gap: 4px; }
.wac-pet-field label { font-size: 13px; font-weight: 600; color: #5C3D2E; }
.wac-pet-field input, .wac-pet-field select {
	border: 1px solid #E7DECF; border-radius: 10px; padding: 10px 12px;
	font-size: 14px; font-family: inherit; background: #fff;
}
.wac-pet-field input:focus, .wac-pet-field select:focus { outline: none; border-color: var(--wac-accent, #C4622D); }
.wac-pet-field--row { flex-direction: row; gap: 12px; }
.wac-pet-field--row > div { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.wac-btn--primary {
	align-self: flex-start; background: var(--wac-accent, #C4622D); color: #fff;
	border: none; border-radius: 999px; padding: 12px 24px; font-size: 14px;
	font-weight: 600; cursor: pointer;
}
.wac-btn--primary:hover { opacity: .9; }
.wac-pet-form-guest { padding: 16px; background: #F2EDE8; border-radius: 10px; }
