/* ============================================================
   Eurocars AI Chatbot – Widget stílusok
   ============================================================ */

/* Lebegő gomb */
#eurocars-chat-fab {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: #fff;
	padding: 0;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(26,46,90,0.35);
    z-index: 99999;
    transition: transform 0.2s, box-shadow 0.2s;
}
#eurocars-chat-fab:hover {
    transform: scale(1.07);
    box-shadow: 0 6px 22px rgba(26,46,90,0.45);
}
#eurocars-chat-fab img {
    width: 56px;
    height: 56px;
}

/* Notification badge */
#eurocars-chat-badge {
    position: absolute;
    top: -3px;
    right: -3px;
    width: 18px;
    height: 18px;
    background: #e8b84b;
    border-radius: 50%;
    font-size: 11px;
    font-weight: 600;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    display: none;
}

/* Chat ablak */
#eurocars-chat-window {
    position: fixed;
    bottom: 96px;
    right: 24px;
    width: 370px;
    max-width: calc(100vw - 32px);
    max-height: 560px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.18);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    z-index: 99998;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    transform: translateY(12px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s ease, transform 0.22s ease;
}
#eurocars-chat-window.ec-open {
    opacity: 1;
    transform: translateY(0);
    pointer-events: all;
}

/* Header */
#eurocars-chat-header {
    background: #fff;
    padding: 14px 16px;
    display: flex;
    align-items: center;
    gap: 11px;
    flex-shrink: 0;
}
.ec-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #e8b84b;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}
.ec-header-info { flex: 1; }
.ec-header-title {
    color: ##D01818;
    font-size: 14px;
    font-weight: 600;
    margin: 0;
    line-height: 1.3;
}
.ec-header-status {
    color: #000;
    font-size: 11px;
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: 2px;
}
.ec-status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #4ade80;
}
#eurocars-chat-close {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    color: rgba(255,255,255,0.6);
    font-size: 20px;
    line-height: 1;
    transition: color 0.15s;
}
#eurocars-chat-close:hover { color: #fff; }

/* Üzenetek terület */
#eurocars-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 14px 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: #f4f6f9;
    scrollbar-width: thin;
    scrollbar-color: #c8d0dc transparent;
}
#eurocars-chat-messages::-webkit-scrollbar { width: 4px; }
#eurocars-chat-messages::-webkit-scrollbar-thumb { background: #c8d0dc; border-radius: 4px; }

/* Buborékok */
.ec-msg {
    max-width: 84%;
    font-size: 13.5px;
    line-height: 1.55;
    padding: 9px 12px;
    border-radius: 14px;
    word-break: break-word;
}
.ec-msg-label {
    font-size: 10.5px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 4px;
    letter-spacing: 0.02em;
}
.ec-msg.bot {
    background: #fff;
    color: #1c1c1e;
    border: 1px solid #e2e8f0;
    border-radius: 4px 14px 14px 14px;
    align-self: flex-start;
}
.ec-msg.user {
    background: #fff;
    color: #000;
    border-radius: 14px 4px 14px 14px;
    align-self: flex-end;
}

/* Quick reply gombok */
.ec-quick-btns {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 8px;
}
.ec-quick-btn {
    font-size: 12px;
    border: 1.5px solid #D01818;
    color: #D01818;
    background: transparent;
    border-radius: 20px;
    padding: 5px 11px;
    cursor: pointer;
    transition: all 0.15s;
    line-height: 1.3;
}
.ec-quick-btn:hover {
    background: #fff;
    color: #D01818;
}

/* WhatsApp gomb */
.ec-wa-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: #25d366;
    color: #fff;
    border: none;
    border-radius: 22px;
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 8px;
    transition: background 0.15s;
    text-decoration: none;
}
.ec-wa-btn:hover { background: #1fb855; }
.ec-wa-btn svg {
    width: 16px;
    height: 16px;
    fill: #fff;
    flex-shrink: 0;
}

/* Typing indicator */
.ec-typing {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 4px 2px;
}
.ec-typing span {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #94a3b8;
    animation: ec-bounce 1.2s infinite;
}
.ec-typing span:nth-child(2) { animation-delay: 0.2s; }
.ec-typing span:nth-child(3) { animation-delay: 0.4s; }
@keyframes ec-bounce {
    0%,60%,100% { transform: translateY(0); }
    30% { transform: translateY(-5px); }
}

/* Input sor */
#eurocars-chat-input-row {
    display: flex;
    gap: 8px;
    padding: 10px 12px;
    border-top: 1px solid #e8edf3;
    background: #fff;
    flex-shrink: 0;
}
#eurocars-chat-input {
    flex: 1;
    border: 1px solid #d0d7e2;
    border-radius: 22px;
    padding: 9px 15px;
    font-size: 13.5px;
    background: #f8fafc;
    color: #1c1c1e;
    outline: none;
    transition: border-color 0.15s;
    font-family: inherit;
}
#eurocars-chat-input:focus { border-color: #fff; background: #fff; }
#eurocars-chat-input::placeholder { color: #94a3b8; }

#eurocars-chat-send {
    width: 38px;
    height: 38px;
    border-radius: 100%;
    background: #D01818;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.15s, transform 0.1s;
	padding: 0;
}
#eurocars-chat-send:hover { background: #243f7a; }
#eurocars-chat-send:active { transform: scale(0.94); }
#eurocars-chat-send svg {
    width: 16px;
    height: 16px;
    fill: #fff;
}

.ec-footer {
    text-align: center;
    font-size: 10.5px;
    color: #94a3b8;
    padding: 5px 0 8px;
    background: #fff;
}

.ec-chat-open #eurocars-chat-fab {
    opacity: 0;
    pointer-events: none;
    transform: scale(0);
}

/* Mobil */
@media (max-width: 420px) {
    #eurocars-chat-window {
        right: 0;
        left: 0;
        bottom: 0;
        width: 100%;
        max-width: 100%;
        max-height: 85vh;
        border-radius: 18px 18px 0 0;
    }
    #eurocars-chat-fab {
        right: 16px;
        bottom: 16px;
    }
}
