:root {
    --b_m_b: #e0c8b5;
    --b_m_u: #c0e2c0;
    --button-color: #282828;
}

.chat-container {
    position: fixed;
    top: 0px;
    bottom: 0;
    left: 0px;
    background-color: rgb(244, 244, 244);
    z-index: 1050;
    border: 1px solid grey;
    border-radius: 10px;
    width: 400px;
    
    display: flex;
    flex-direction: column;
}

.header-chat {
    padding-left: 20px;
    padding-right: 20px;
    padding-top: 10px;
    padding-bottom: 10px;
    flex: 0 0 auto;
}

.body-chat {
    flex: 1;              /* занимает всё свободное место */
    overflow-y: auto;
    overflow-x: hidden;
}

.input-chat {
    flex: 0 0 auto;
    height: 65px;
}

/* .chat-icon {
    position: fixed;
    top: 70%;
    left: 100px;
    background-color: rgb(218, 218, 218);
    z-index: 1050;
    border: 1px solid grey;
    border-radius: 10px;
} */

.chat-hr {
    margin-top: 0;
    margin-bottom: 10px;
}

/* форма */
.chat-form {
    display: flex;
    width: 100%;
    border-radius: 25px;
    overflow: hidden;
    border: 1px solid #ccc;
    background-color: white;
}

/* инпут */
.chat-input {
    border: none;
    padding: 10px 15px;
    font-size: 1em;
    border-radius: 25px 0 0 25px; /* слева округление */
    outline: none;
}

/* кнопка */
.chat-send-btn {
    background-color: #A0835C;
    border: none;
    padding: 0 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 25px 25px 25px 25px;
}

/* hover */
.chat-send-btn:hover {
    background-color: #c7a477;
}

.chat-send-btn:hover svg {
    color: #fff;
}

/* svg в кнопке */
.chat-send-btn svg {
    display: block;
    width: 20px;
    height: 20px;
    color: #f0f0f0;
}

.message-user {
    position: relative;
    margin-left: auto;
    margin-right: 15px;
    margin-bottom: 10px;
    padding: 2px 10px 10px 10px;
    background-color: #ffffff;
    max-width: 70%;
    text-align: left;
    font: 400 .9em 'Open Sans', sans-serif;
    border: 1px solid var(--b_m_u);
    border-radius: 10px;
}

.message-user:after {
    content: '';
    position: absolute;
    width: 0;
    height: 0;
    border-bottom: 10px solid #ffffff;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    bottom: 0;
    right: -10px;
}

.message-user:before {
    content: '';
    position: absolute;
    width: 0;
    height: 0;
    border-bottom: 12px solid var(--b_m_u);
    border-left: 11px solid transparent;
    border-right: 11px solid transparent;
    bottom: -1px;
    right: -12px;
}

.message-bot {
    position: relative;
    margin-left: 15px;
    margin-right: auto;
    margin-bottom: 10px;
    padding: 2px 10px 10px 10px;
    background-color: #ffffff;
    max-width: 70%;
    text-align: left;
    font: 400 .9em 'Open Sans', sans-serif;
    border: 1px solid var(--b_m_b);
    border-radius: 10px;
}

.message-bot:after {
    content: '';
    position: absolute;
    width: 0;
    height: 0;
    border-bottom: 10px solid #ffffff;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    bottom: 0;
    left: -10px;
}

.message-bot:before {
    content: '';
    position: absolute;
    width: 0;
    height: 0;
    border-bottom: 12px solid var(--b_m_b);
    border-left: 11px solid transparent;
    border-right: 11px solid transparent;
    bottom: -1px;
    left: -12px;
}

.message-content {
    padding: 0;
    font-size: 14px;
    color:black
}

.message-name {
    padding: 0;
    font-size: 12px;
}

.message-timestamp-right {
    position: absolute;
    font-size: 11px;
    font-weight: 300;
    bottom: 5px;
    right: 5px;
}

.message-timestamp-left {
    position: absolute;
    font-size: 11px;
    font-weight: 300;
    bottom: 5px;
    left: 5px;
}

.chat-icon {
    position: fixed;
    bottom: 30%;
    right: 6%;
    cursor: pointer;
    z-index: 2000;
    border-radius: 22px;
    background-color: var(--button-color);
    padding: 2px 6px;
    filter: 
        drop-shadow(4px 6px 4px #303030ce);
}

/* цвет иконки */
.chat-bubble {
    color: var(--button-color);
    fill: var(--button-color);

    animation: shake-cycle 10.5s ease-in-out infinite;
    animation-delay: 5s;
    transform-origin: center;
}

@keyframes shake-cycle {
    0%   { transform: rotate(0deg); }
    1%   { transform: rotate(-10deg); }
    2%  { transform: rotate(10deg); }
    3%  { transform: rotate(-10deg); }
    4%  { transform: rotate(10deg); }
    5%  { transform: rotate(-5deg); }
    6%  { transform: rotate(0deg); }
    100% { transform: rotate(0deg); }
}
