﻿/* Modal Heading */
.chat-modal-content h2 {
    padding: 10px;
    text-align: center;
    border-radius: 5px; /* Rounded corners */
    margin: 0 -20px 15px; /* Extend the margin to cover the full width */
    color: #333; /* Text color */
    background-color: #f0f0f0; /* Light background color for contrast */
    width: calc(100% + 34px); /* Ensure full width coverage */
    box-sizing: border-box; /* Include padding and border in width calculation */
    margin-top:-16px;
}


.chat-icon {
    position: fixed;
    bottom: 20px;
    right: 20px;
    cursor: pointer;
    z-index: 1000;
}

    .chat-icon img {
        width: 50px;
        height: 50px;
        border-radius: 50%;
        box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
    }

/* Modal Background */
.chat-modal {
    display: none; /* Hidden by default */
    position: fixed;
    bottom: 0;
    right: 0;
    width: 350px;
    max-height: 80%;
    background-color: #fefefe;
    box-shadow: 0px 0px 15px rgba(0, 0, 0, 0.2);
    z-index: 1001;
    border-radius: 10px 10px 0 0;
    overflow-y: auto;
    transform: translateY(100%);
    transition: transform 0.3s ease-in-out, display 0s linear 0.3s; /* Delayed display property */
}

    .chat-modal.open {
        display: block; /* Show modal when open */
        transform: translateY(0);
        transition: transform 0.3s ease-in-out;
    }

/* Modal Content */
.chat-modal-content {
    padding: 15px; /* Reduced padding */
}

/* Close Button */
.close {
    color: #aaa;
    float: right;
    font-size: 24px; /* Adjusted font size */
    font-weight: bold;
    position: absolute;
    top: 3px;
    right: 10px;
}

    .close:hover,
    .close:focus {
        color: black;
        text-decoration: none;
        cursor: pointer;
    }

/* Form Fields */
#chat-form {
    display: flex;
    flex-direction: column;
    gap: 10px; /* Added gap for spacing */
}

    #chat-form label {
        font-size: 14px; /* Adjusted font size for labels */
    }

    #chat-form input,
    #chat-form textarea {
        width: 100%;
        padding: 8px;
        border-radius: 5px;
        border: 1px solid #ccc;
    }

    #chat-form textarea {
        resize: vertical; /* Allow vertical resize only */
    }

    #chat-form button {
        padding: 10px;
        background-color: #007bff;
        color: white;
        border: none;
        border-radius: 5px;
        cursor: pointer;
        font-size: 16px; /* Adjusted font size */
    }

        #chat-form button:hover {
            background-color: #0056b3;
        }

/* Responsive Design */
@media (max-width: 480px) {
    .chat-modal {
        width: 100%;
        bottom: 0;
        right: 0;
        border-radius: 0;
    }

    .chat-modal-content {
        padding: 15px;
    }

    .close {
        font-size: 20px; /* Adjusted for smaller screens */
    }

    #chat-form button {
        font-size: 14px;
        padding: 10px;
    }
}
