/* Styl pro chat widget */
body {
    font-family: "Poppins", sans-serif;
}

#chat-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9999;
    font-family: "Poppins", sans-serif;
}

/* Efekt rozmazání pozadí */
.chat-blur {
    filter: blur(4px);
    pointer-events: none; /* Zakáže interakce se skrytým obsahem */
    transition: filter 0.3s ease-in-out;
}

#message-suggestions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 10px;
}

.deep-chat-button {
    background: white;
    padding: 8px 12px;
    border: 1px solid rgb(212, 212, 212);
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    line-height: 18px;
    width: fit-content;
    transition: background 0.3s;
    color: black;
    text-align: center;
}

.deep-chat-button:hover {
    background: #fc5a8d;
    color: white;
    border-color: #fc5a8d;
}
#chat-box {
    display: none;
    flex-direction: column;
    width: 90vw; /* Základní šířka */
    max-width: 400px; /* Maximální šířka */
    height: 80vh; /* Výška 80% viewportu */
    max-height: 600px; /* Maximální výška */
    border-radius: 12px;
    background: white;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

/* Mobilní verze (do 480px šířky) */
@media screen and (max-width: 480px) {
    #chat-box {
        width: 90vw;
        max-width: 360px;
        height: 85vh;
        max-height: none;
    }

    #chat-input {
        font-size: 13px;
        padding: 8px;
    }

    #send-btn {
        padding: 8px 10px;
        font-size: 14px;
    }

    #chat-header {
        padding: 15px;
        font-size: 14px;
    }

    #close-chat {
        font-size: 30px;
    }
}

/* Tablet (480px - 768px) */
@media screen and (max-width: 768px) {
    #chat-box {
        width: 85vw;
        max-width: 380px;
        height: 75vh;
        max-height: none;
    }
}

/* Vzhled scrollbarů */
#chat-messages::-webkit-scrollbar {
    width: 4px; /* Zmenšený scrollbar pro mobil */
}
/* Header */
#chat-header {
    background: #fc5a8d;
    color: white;
    padding: 20px;
    font-size: 16px;
    font-weight: bold;
    text-align: left;
    position: relative;
    border-top-left-radius: 12px;
    border-top-right-radius: 12px;
}

/* Tlačítko zavření */
#close-chat {
    position: absolute;
    right: 20px;
    cursor: pointer;
    font-size: 35px;
    bottom: 5px;
    transition: color 0.2s;
}

#close-chat:hover {
    color: #fff3f3;
}

/* Oblast se zprávami */
#chat-messages {
    flex-grow: 1;
    padding: 10px;
    overflow-y: auto;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    gap: 5px;
    scrollbar-width: thin;
    scrollbar-color: #fc5a8d #f5f5f5;
}

/* Vzhled scrollbarů */
#chat-messages::-webkit-scrollbar {
    width: 6px;
}

#chat-messages::-webkit-scrollbar-track {
    background: #f5f5f5;
}

#chat-messages::-webkit-scrollbar-thumb {
    background: #fc5a8d;
    border-radius: 5px;
}

/* Styl zpráv */
.user-msg, .bot-msg {
    max-width: 75%;
    padding: 11px 15px;
    border-radius: 15px;
    font-size: 14px;
    line-height: 21px;
}

/* Zprávy uživatele */
.user-msg {
    align-self: flex-end;
    background: #fc5a8d;
    color: white;
    border-bottom-right-radius: 3px;
}

/* Zprávy bota */
.bot-msg {
    align-self: flex-start;
    background: white;
    padding: 10px;
    border-radius: 10px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    font-size: 14px;
    max-width: 80%;
    color: #4d5663;
}

/* Tučné nadpisy v odpovědích */
.bot-msg strong {
   /* display: block;*/
       display: inline-block;
    font-size: 16px;
    font-weight: bold;
       margin-top: 18px;
}

/* Seznamy */
.bot-msg ul {
    margin: 5px 0;
    padding-left: 20px;
}

.bot-msg li {
    margin-bottom: 5px;
}

/* Bloky kódu */
.bot-msg pre {
    background: #f4f4f4;
    padding: 8px;
    border-radius: 5px;
    overflow-x: auto;
}

.bot-msg.error {
    background: #FFDDDD;
    color: red;
}

/* Vstupní pole */
#chat-input-area {
    display: flex;
    padding: 10px;
    background: white;
}
#chat-input-area {
    display: flex;
    padding: 8px;
    background: white;
}

/* Input */
#chat-input {
    flex-grow: 1;
    padding: 10px;
    border: none;
    border-radius: 25px;
    outline: none;
    color: gray;
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    background: #f5f5f5;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Tlačítko odeslání */
#send-btn {
    color: #fc5a8d;
    border: none;
    
    border-radius: 50%;
    cursor: pointer;
    font-size: 24px;
    transition: background 0.3s ease-in-out;
    
    background: none;
    text-shadow: 2px 3px 2px #9b0f696b;
}

#send-btn:hover {
    color: #e94176;
}
/* Tlačítko pro otevření chatu */
#chat-toggle {
    display: block;
    background: #fc5a8d;
    color: white;
    border: none;
    
    border-radius: 10px;
    font-size: 16px;
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    transition: background 0.3s ease-in-out;
    padding: 10px 11px;
}

#chat-toggle:hover {
    background: #e04e7d;
}

/* Loader animace */
.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px;
}

.dot {
    width: 8px;
    height: 8px;
    margin: 0 3px;
    background-color: #fc5a8d;
    border-radius: 50%;
    display: inline-block;
    animation: blink 1.4s infinite both;
}

.dot:nth-child(2) { animation-delay: 0.2s; }
.dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes blink {
    0% { opacity: 0.2; }
    20% { opacity: 1; }
    100% { opacity: 0.2; }
}

/* Úvodní panel */
.intro-panel {
    
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    max-width: 350px;
    z-index: 100;
}

.intro-panel p {
    font-size: 13px;
    margin-bottom: 30px;
}

.intro-panel a {
    color: #fc5a8d;
    text-decoration: none;
}

.chatButton {
    background: #fc5a8d;
    color: white;
    border: none;
    padding: 10px 14px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.3s ease-in-out;
}

.chatButton:hover {
    background: #e04e7d;
}
