/* =============================================
   bot-chat.css — תוספות לעיצוב הקיים של הבוט
   מכיל רק מחלקות חדשות שנוצרות ע"י bot-chat.js.
   אין כאן עיצוב מחדש של .bot-card / .bot-chat-bubble וכו'.
   ============================================= */

.bot-sec {
    --bot-accent: #1f7a4d;
    --bot-accent-soft: #e8f5ee;
    --bot-ink: #1a365d;
    --bot-muted: #718096;
    --bot-line: #e2e8f0;
}

/* ---- מעבר בין כרטיס הנושאים לכרטיס הצ'אט ----
   אם ה-CSS הקיים כבר מנהל את ההחלפה — אפשר למחוק את שלוש השורות הבאות */
/* -- Amir 30/8/2026
.bot-panels-container .bot-chat-card { display: none; }
.bot-panels-container.bot-chat-open .bot-card { display: none; }
.bot-panels-container.bot-chat-open .bot-chat-card { display: flex; }
*/

/* חותמת זמן — מוסתרת כברירת מחדל (משמשת את הסקריפט כסימן לסיום הקלדה) */
.bot-chat-time { display: none; }

/* ---- אינדיקטור הקלדה ---- */
.bot-typing { display: inline-flex; align-items: center; gap: 4px; }
.bot-typing i {
    width: 6px; height: 6px; border-radius: 50%;
    background: var(--bot-muted); display: inline-block;
    animation: botTypingDot 1.2s infinite ease-in-out;
}
.bot-typing i:nth-child(2) { animation-delay: .18s; }
.bot-typing i:nth-child(3) { animation-delay: .36s; }
@keyframes botTypingDot {
    0%, 60%, 100% { opacity: .25; transform: translateY(0); }
    30%           { opacity: 1;   transform: translateY(-3px); }
}
@media (prefers-reduced-motion: reduce) {
    .bot-typing i { animation: none; opacity: .5; }
}

.bot-chat-bubble.bot-chat-loading { display: flex; align-items: center; gap: 10px; }
.bot-loading-text { font-size: 13px; color: var(--bot-muted); }

.bot-chat-bubble.bot-chat-error {
    background: #fff5f5; border: 1px solid #fed7d7; color: #c53030;
}

/* תמונה שנשלחה */
.bot-chat-bubble-img img {
    max-width: 180px; max-height: 180px;
    border-radius: 12px; display: block; object-fit: cover;
}

/* ---- טיפוגרפיה בתוך בועת AI ---- */
.bot-chat-msg-ai .bot-chat-bubble p { margin: 0 0 8px; }
.bot-chat-msg-ai .bot-chat-bubble p:last-child { margin-bottom: 0; }
.bot-chat-msg-ai .bot-chat-bubble ul { margin: 4px 0 8px; padding-inline-start: 18px; }
.bot-chat-msg-ai .bot-chat-bubble li { margin-bottom: 3px; }
.bot-chat-msg-ai .bot-chat-bubble .bot-step {
    margin: 4px 0; padding: 8px 12px; background: #f7fafc;
    border: 1px solid var(--bot-line); border-radius: 8px;
}
.bot-chat-msg-ai .bot-chat-bubble .bot-hr {
    border: none; border-top: 1px solid var(--bot-line); margin: 10px 0;
}
.bot-chat-msg-ai .bot-chat-bubble .summary-list { list-style: none; padding: 0; }
.bot-chat-msg-ai .bot-chat-bubble .summary-list .q { color: var(--bot-muted); }

/* ---- אפשרויות הסימולטור ---- */
.bot-sim-options { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; }
.bot-sim-option-btn {
    display: flex; align-items: center; gap: 8px;
    background: #fff; border: 1.5px solid var(--bot-line); border-radius: 10px;
    padding: 9px 12px; font: inherit; font-size: 14px; color: var(--bot-ink);
    text-align: start; cursor: pointer; transition: border-color .2s, background .2s;
}
.bot-sim-option-btn:hover { border-color: var(--bot-accent); background: var(--bot-accent-soft); }
.bot-sim-option-num {
    flex-shrink: 0; width: 22px; height: 22px; border-radius: 50%;
    background: var(--bot-accent); color: #fff;
    display: inline-flex; align-items: center; justify-content: center; font-size: 12px;
}

/* ---- מסך אישור בסימולטור ---- */
.bot-sim-confirm-title { font-weight: 700; color: var(--bot-ink); margin-bottom: 10px; }
.bot-sim-confirm-list {
    background: #f7fafc; border: 1px solid var(--bot-line);
    border-radius: 10px; padding: 10px 14px; margin-bottom: 12px;
}
.bot-sim-confirm-row { font-size: 13.5px; color: #2d3748; padding: 3px 0; }
.bot-sim-confirm-row .q { color: var(--bot-muted); }
.bot-sim-confirm-btns { display: flex; gap: 8px; margin-top: 10px; }
.bot-sim-btn {
    flex: 1; border-radius: 10px; padding: 10px; font: inherit; font-weight: 600;
    font-size: 14px; cursor: pointer; border: none;
}
.bot-sim-btn-confirm { background: var(--bot-accent); color: #fff; }
.bot-sim-btn-reject  { background: #f7fafc; color: #c53030; border: 1.5px solid #fed7d7; }

/* ---- כרטיסי מוצר (נושא "המומלצים") ---- */
.bot-chat-bubble .answer-title {
    font-size: 14px; font-weight: 700; color: var(--bot-ink);
    margin-bottom: 10px; padding-bottom: 8px; border-bottom: 1.5px solid var(--bot-line);
}
.bot-chat-bubble .product-card {
    background: #fff; border: 1px solid var(--bot-line); border-radius: 10px;
    padding: 11px 13px; margin-bottom: 10px;
}
.bot-chat-bubble .product-name { font-weight: 700; color: var(--bot-ink); margin-bottom: 6px; }
.bot-chat-bubble .koshers-label { font-size: 11px; color: var(--bot-muted); margin-bottom: 5px; }
.bot-chat-bubble .koshers-label-all { color: #b7791f; font-weight: 600; }
.bot-chat-bubble .koshers-row,
.bot-chat-bubble .globals-row { display: flex; flex-wrap: wrap; gap: 5px; }
.bot-chat-bubble .tag-kosher,
.bot-chat-bubble .tag-global {
    display: inline-block; font-size: 12px; padding: 3px 9px; border-radius: 999px;
    background: var(--bot-accent-soft); color: #14603c; border: 1px solid #bfe0cd;
}
.bot-chat-bubble .tag-note {
    display: block; margin-top: 7px; font-size: 12px; color: #7b5b16;
    background: #fffbeb; border: 1px solid #fde68a; border-radius: 8px; padding: 6px 9px;
}
.bot-chat-bubble .global-section {
    background: #f0fdf4; border: 1.5px solid #a7d5b2; border-radius: 10px;
    padding: 11px 13px; margin-bottom: 10px;
}
.bot-chat-bubble .global-title {
    font-size: 11px; font-weight: 700; color: #065f46; margin-bottom: 6px;
}

/* ---- מוצרים ממאגר ikr ---- */
.ikr-section {
    margin-top: 12px; padding-top: 10px; border-top: 1px dashed var(--bot-line);
}
.ikr-title { font-size: 12.5px; font-weight: 700; color: var(--bot-ink); margin-bottom: 6px; }
.ikr-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.ikr-list a { color: var(--bot-accent); font-size: 13px; font-weight: 500; text-decoration: none; }
.ikr-list a:hover { text-decoration: underline; }
.ikr-meta { display: block; font-size: 11.5px; color: var(--bot-muted); }
.ikr-footer { margin-top: 8px; font-size: 12px; }
.ikr-footer a { color: var(--bot-accent); }

/* ---- קישורי מאמרים / יוטיוב ---- */
.bot-links-msg { background: #eff6ff !important; border: 1px solid #bfdbfe !important; }
.bot-links-label { font-size: 12px; font-weight: 700; color: #1d4ed8; margin-bottom: 8px; }
.bot-links-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 5px; }
.bot-links-list a {
    color: #1d4ed8; font-size: 13px; font-weight: 500; text-decoration: none;
    display: flex; align-items: center; gap: 5px;
}
.bot-links-list a:hover { text-decoration: underline; }
.bot-links-list .arr { color: #93c5fd; flex-shrink: 0; }

.bot-yt-msg { background: #fff5f5 !important; border: 1px solid #fed7d7 !important; }
.bot-yt-label { font-size: 12px; font-weight: 700; color: #c53030; margin-bottom: 8px; }
.bot-yt-link {
    display: flex; align-items: center; gap: 8px; color: #c53030;
    font-size: 13px; font-weight: 500; text-decoration: none; padding: 4px 0;
}
.bot-yt-link:hover { text-decoration: underline; }
.bot-yt-badge {
    background: #f00; color: #fff; border-radius: 3px; padding: 1px 5px;
    font-size: 11px; flex-shrink: 0;
}

/* ---- רמז למעבר נושא ---- */
.bot-topic-hint {
    background: #fffbeb; border: 1px solid #fde68a; border-radius: 12px;
    padding: 10px 14px; margin: 6px 0 2px;
    display: flex; align-items: center; gap: 10px; font-size: 13px; color: #78350f;
}
.bot-topic-hint-btn {
    background: #d97706; color: #fff; border: none; border-radius: 8px;
    padding: 6px 12px; font: inherit; font-size: 12.5px; font-weight: 600;
    cursor: pointer; white-space: nowrap; flex-shrink: 0;
}

/* ---- מצב עיבוד ---- */
.bot-chat-card.is-busy .bot-chat-send-btn,
.bot-chat-card.is-busy .bot-chat-attach-btn { opacity: .5; pointer-events: none; }


.bot-restart { cursor: pointer; text-decoration: underline; color: var(--bs-primary); }