/* Container */
.vb-widget-container {
    position: relative;
    width: 100%;
    min-height: 90px;
    display: flex;
    justify-content: center;
    margin: 20px 0;
}

#vb-chat-icon {
    cursor: pointer;
    text-align: center;
    position: relative;
    z-index: 100;
}

#vb-chat-icon img, .vb-default-icon {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transition: transform 0.2s;
}

.vb-default-icon {
    background: #0073aa;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 35px;
}

#vb-chat-icon:hover img {
    transform: scale(1.05);
}

.vb-icon-label {
    display: block;
    margin-top: 5px;
    background: #444;
    color: #fff;
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: bold;
}

/* Chat Fenster */
#vb-chat-window {
    position: fixed; 
    bottom: 20px;
    width: 350px;
    height: 500px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    display: flex;
    flex-direction: column;
    z-index: 99999;
    overflow: hidden;
}

.vb-pos-left { left: 20px; right: auto; }
.vb-pos-right { right: 20px; left: auto; }

#vb-chat-window.vb-expanded {
    width: 600px;
    height: 700px;
    max-width: 90vw;
    max-height: 90vh;
}

.vb-hidden { display: none !important; }

.vb-chat-header {
    background: #23282d;
    color: #fff;
    padding: 12px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: bold;
}

.vb-controls button {
    background: none;
    border: none;
    color: #fff;
    font-size: 16px;
    cursor: pointer;
    margin-left: 8px;
}

#vb-chat-messages {
    flex: 1;
    padding: 15px;
    background: #f1f1f1;
    overflow-y: auto;
    font-size: 14px;
    line-height: 1.5;
}

/* Markdown Styles (Marked.js Output) */
/* --- Kompakte, einzeilige Textformatierung im Chat --- */
.markdown-body ul, .markdown-body ol {
    margin: 5px 0 5px 20px !important; /* Abstände oben/unten auf 5px reduziert */
    padding-left: 0 !important;
    list-style-type: disc !important;
}
.markdown-body li { margin-bottom: 2px; } /* Abstand zwischen Listenpunkten verringert */
.markdown-body p { margin-bottom: 5px; } /* Abstand nach Absätzen verringert */
.markdown-body strong { color: #0073aa; }
.markdown-body h1, .markdown-body h2, .markdown-body h3 { 
    font-size: 1.1em; margin: 5px 0; font-weight: bold; /* Abstände bei Überschriften verringert */
}
/* Entfernt den allerletzten Abstand in der Sprechblase, damit es unten bündig abschließt */
.markdown-body *:last-child {
    margin-bottom: 0 !important;
}

.vb-message {
    margin-bottom: 15px;
    padding: 10px 14px;
    border-radius: 18px;
    max-width: 85%;
    word-wrap: break-word;
}

.vb-bot {
    background: #fff;
    border-bottom-left-radius: 2px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.vb-user {
    background: #0073aa;
    color: #fff;
    border-bottom-right-radius: 2px;
    margin-left: auto;
}

.vb-chat-input {
    padding: 10px;
    background: #fff;
    border-top: 1px solid #ddd;
    display: flex;
}

#vb-user-input {
    flex: 1;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

#vb-send-btn {
    margin-left: 8px;
    background: #0073aa;
    color: white;
    border: none;
    border-radius: 4px;
    width: 40px;
    cursor: pointer;
}

.vb-loading {
    padding: 5px 15px;
    background: #f1f1f1;
    color: #888;
    font-size: 20px;
    font-weight: bold;
}
.vb-dots span { animation: blink 1.4s infinite both; }
.vb-dots span:nth-child(2) { animation-delay: .2s; }
.vb-dots span:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 0% { opacity: .2; } 20% { opacity: 1; } 100% { opacity: .2; } }