/* ── CHATBOT JAÉN ACOGE — ESTILOS GLOBALES ── */
#jac-launcher-wrap { position: fixed; bottom: 28px; right: 28px; z-index: 9999; }
#jac-launcher {
    height: 64px; width: 64px;
    border-radius: 32px;
    border: none; cursor: pointer;
    background: linear-gradient(135deg, #f98930, #c2410c);
    box-shadow: 0 8px 32px rgba(249,137,48,0.5);
    display: flex; align-items: center; justify-content: center;
    gap: 0; padding: 0; overflow: hidden;
    animation: chatPulse 2.5s infinite;
    transition: width 0.55s cubic-bezier(.25,1,.5,1), box-shadow 0.3s;
}
#jac-launcher:hover { box-shadow: 0 12px 40px rgba(249,137,48,0.65); animation: none; }
#jac-launcher.intro-open { width: 316px; animation: none; }
#jac-launcher.open { animation: none; }
@keyframes chatPulse {
    0%,100% { box-shadow: 0 8px 32px rgba(249,137,48,0.5), 0 0 0 0 rgba(249,137,48,0.4); }
    50% { box-shadow: 0 8px 32px rgba(249,137,48,0.5), 0 0 0 16px rgba(249,137,48,0); }
}
.jac-icon-wrap { display: flex; align-items: center; justify-content: center; width: 64px; height: 64px; flex-shrink: 0; font-size: 24px; color: #fff; pointer-events: none; }
.icon-close { display: none; }
#jac-launcher.open .icon-chat { display: none; }
#jac-launcher.open .icon-close { display: flex; }
#jac-intro-text {
    width: 0; overflow: hidden; white-space: nowrap;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 700; font-size: 13px; color: #fff; pointer-events: none;
    transition: width 0.5s cubic-bezier(.25,1,.5,1), margin-right 0.5s cubic-bezier(.25,1,.5,1);
    margin-right: 0;
}
#jac-launcher.intro-open #jac-intro-text { width: 228px; margin-right: 12px; }
#jac-badge {
    position: absolute; top: -3px; right: -3px;
    width: 22px; height: 22px;
    background: #ef4444; border-radius: 50%; border: 2px solid white;
    font-size: 11px; font-weight: 700; color: white;
    display: flex; align-items: center; justify-content: center;
    animation: badge-pop 0.4s cubic-bezier(.34,1.56,.64,1); pointer-events: none;
}
@keyframes badge-pop { from { transform: scale(0); } to { transform: scale(1); } }
#jac-window {
    position: fixed; bottom: 106px; right: 28px; z-index: 9998;
    width: 390px; max-width: calc(100vw - 36px);
    height: 600px; max-height: calc(100vh - 120px);
    background: #fff; border-radius: 24px;
    box-shadow: 0 24px 64px rgba(0,0,0,0.18), 0 0 0 1px rgba(0,0,0,0.06);
    display: flex; flex-direction: column; overflow: hidden;
    transform-origin: bottom right;
    transform: scale(0.85) translateY(20px); opacity: 0; pointer-events: none;
    transition: transform 0.35s cubic-bezier(.34,1.56,.64,1), opacity 0.25s ease;
}
#jac-window.open { transform: scale(1) translateY(0); opacity: 1; pointer-events: all; }
.jac-header { background: linear-gradient(135deg, #111827 0%, #1f2937 100%); padding: 16px 18px; display: flex; align-items: center; gap: 12px; flex-shrink: 0; border-bottom: 1px solid rgba(249,137,48,0.2); }
.jac-header-icon { width: 44px; height: 44px; flex-shrink: 0; background: linear-gradient(135deg, #f98930, #c2410c); border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 18px; color: #fff; box-shadow: 0 4px 14px rgba(249,137,48,0.4); }
.jac-header-text { flex: 1; }
.jac-header-name { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 800; font-size: 14px; color: #fff; }
.jac-header-status { display: flex; align-items: center; gap: 5px; font-size: 11px; color: #9ca3af; margin-top: 2px; }
.status-dot { width: 7px; height: 7px; background: #22c55e; border-radius: 50%; animation: blink 2s infinite; }
@keyframes blink { 0%,100% { opacity:1; } 50% { opacity:0.3; } }
.jac-close-btn { background: rgba(255,255,255,0.1); border: none; cursor: pointer; width: 32px; height: 32px; border-radius: 10px; display: flex; align-items: center; justify-content: center; color: #9ca3af; transition: background 0.2s, color 0.2s; flex-shrink: 0; }
.jac-close-btn:hover { background: rgba(255,255,255,0.2); color: #fff; }
#jac-messages-chat { flex: 1; overflow-y: auto; padding: 18px 14px; display: flex; flex-direction: column; gap: 14px; background: #f8fafc; scroll-behavior: smooth; }
#jac-messages-chat::-webkit-scrollbar { width: 4px; }
#jac-messages-chat::-webkit-scrollbar-thumb { background: #e2e8f0; border-radius: 4px; }
.msg-row { display: flex; align-items: flex-end; gap: 8px; animation: msg-in 0.3s ease-out; }
@keyframes msg-in { from { opacity:0; transform:translateY(10px); } to { opacity:1; transform:translateY(0); } }
.msg-row.user { flex-direction: row-reverse; }
.msg-avatar { width: 30px; height: 30px; flex-shrink: 0; border-radius: 10px; background: linear-gradient(135deg, #f98930, #c2410c); display: flex; align-items: center; justify-content: center; font-size: 13px; color: #fff; }
.msg-row.user .msg-avatar { background: linear-gradient(135deg, #6366f1, #4f46e5); }
.msg-bubble { max-width: 82%; padding: 12px 16px; border-radius: 20px; font-size: 14px; line-height: 1.6; }
.msg-row.bot .msg-bubble { background: #fff; color: #1f2937; border-radius: 4px 20px 20px 20px; box-shadow: 0 4px 15px rgba(0,0,0,0.05); border: 1px solid #f1f5f9; }
.msg-row.user .msg-bubble { background: linear-gradient(135deg, #f98930, #ea6c10); color: #fff; border-radius: 20px 20px 4px 20px; box-shadow: 0 4px 12px rgba(249,137,48,0.3); font-weight: 500; }
.msg-bubble ul { padding-left: 20px; margin: 8px 0; }
.msg-bubble li { margin-bottom: 5px; }
.msg-bubble a { color: #f98930; font-weight: 700; text-decoration: underline; }
.typing-row { display: flex; align-items: flex-end; gap: 10px; animation: msg-in 0.3s ease-out; padding: 4px 0; }
.typing-bubble { background: #fff; border-radius: 4px 20px 20px 20px; box-shadow: 0 4px 15px rgba(0,0,0,0.05); border: 1px solid #f1f5f9; padding: 14px 18px; display: flex; gap: 6px; align-items: center; }
.typing-bubble span { width: 8px; height: 8px; background: #cbd5e1; border-radius: 50%; animation: typing 1.2s infinite; display: block; }
.typing-bubble span:nth-child(2) { animation-delay: 0.2s; }
.typing-bubble span:nth-child(3) { animation-delay: 0.4s; }
@keyframes typing { 0%,60%,100% { transform: translateY(0); background: #cbd5e1; } 30% { transform: translateY(-8px); background: #f98930; } }
.date-divider { text-align: center; font-size: 11px; font-weight: 600; color: #94a3b8; padding: 12px 0; text-transform: uppercase; letter-spacing: 0.05em; }
#jac-options { padding: 12px 14px; border-top: 1px solid #f1f5f9; background: #fff; display: flex; flex-direction: column; gap: 8px; flex-shrink: 0; }
.options-label { font-size: 11px; font-weight: 800; color: #b0b9c8; text-transform: uppercase; letter-spacing: 0.1em; padding: 0 4px 4px; }
#options-grid { display: flex; flex-direction: column; gap: 6px; max-height: 160px; overflow-y: auto; padding-right: 4px; }
#options-grid::-webkit-scrollbar { width: 4px; }
#options-grid::-webkit-scrollbar-thumb { background: #e2e8f0; border-radius: 4px; }
.opt-btn { width: 100%; background: #f8fafc; border: 1.5px solid #e2e8f0; border-radius: 14px; padding: 10px 16px; font-size: 13.5px; font-family: 'Inter', sans-serif; font-weight: 600; color: #334155; cursor: pointer; transition: all 0.2s ease; display: flex; align-items: center; gap: 12px; text-align: left; }
.opt-btn .opt-icon { width: 22px; text-align: center; flex-shrink: 0; font-size: 15px; color: #64748b; transition: color 0.2s; }
.opt-btn .opt-arrow { margin-left: auto; color: #cbd5e1; font-size: 11px; transition: all 0.2s; }
.opt-btn:hover { border-color: #f98930; color: #c2410c; background: #fff7ed; box-shadow: 0 4px 12px rgba(249,137,48,0.1); }
.opt-btn:hover .opt-icon { color: #f98930; }
.opt-btn:hover .opt-arrow { color: #f98930; transform: translateX(3px); }
.opt-btn:active { transform: scale(0.98); }
.opt-btn.back { background: #f1f5f9; border-color: #e2e8f0; color: #64748b; font-size: 13px; margin-bottom: 4px; }

#jac-input-container { padding: 12px 14px 16px; background: #fff; border-top: 1px solid #f1f5f9; display: flex; gap: 8px; align-items: center; }
#jac-input { flex: 1; background: #f1f5f9; border: 1.5px solid transparent; border-radius: 12px; padding: 10px 14px; font-size: 14px; outline: none; transition: all 0.2s; font-family: 'Inter', sans-serif; }
#jac-input:focus { background: #fff; border-color: #f98930; box-shadow: 0 0 0 4px rgba(249,137,48,0.08); }
#jac-send { width: 42px; height: 42px; border-radius: 12px; border: none; background: #f98930; color: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center; font-size: 16px; transition: all 0.2s; flex-shrink: 0; }
