/* Chat Button (Floating) */
.chat-toggle-btn {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background-color: #203669;
    color: white;
    border: none;
    border-radius: 50%;
    padding: 14px;
    font-size: 26px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 100000;
    transition: all 0.2s ease;
    font-family: inherit;
    width: 65px;
    height: 65px;
    justify-content: center;
}

.chat-toggle-btn:hover {
    background-color: #eb6308;
    transform: scale(1.02);
}

/* Chat Window */
.chat-window {
    position: fixed;
    bottom: 90px;
    right: 24px;
    width: 380px;
    max-width: calc(100vw - 40px);
    height: 560px;
    background: white;
    border-radius: 28px;
    box-shadow: 0 20px 35px rgba(0,0,0,0.25);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: scale(0);
    opacity: 0;
    transform-origin: bottom right;
    transition: transform 0.2s ease, opacity 0.2s ease;
    z-index: 100001;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

.chat-window.open {
    transform: scale(1);
    opacity: 1;
}

/* Chat Header */
.chat-header {
    background: #203669;
    color: white;
    padding: 16px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #2d3e54;
}

.chat-header h3 {
    font-size: 1.3rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #fff;
}

.close-chat {
    background: none;
    border: none;
    color: white;
    font-size: 26px;
    cursor: pointer;
    line-height: 1;
    opacity: 0.8;
}

.close-chat:hover {
    opacity: 1;
}

/* Messages Area */
.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 16px 12px;
    background: #f9fafc;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Message Bubbles */
.message {
    display: flex;
    animation: fadeInUp 0.2s ease;
}

.user-message {
    justify-content: flex-end;
}

.assistant-message {
    justify-content: flex-start;
}

.message-content {
    max-width: 85%;
    padding: 10px 14px;
    border-radius: 20px;
    font-size: 14px;
    line-height: 1.45;
    word-wrap: break-word;
    background: white;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.user-message .message-content {
    background: #1e2a3e;
    color: white;
    border-bottom-right-radius: 4px;
}

.assistant-message .message-content {
    background: #e9ecef;
    color: #1a2c3e;
    border-bottom-left-radius: 4px;
}

/* Buttons grid */
.option-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 6px;
    margin-bottom: 6px;
}

.chat-option-btn {
    background: white;
    border: 1.5px solid #eb6608;
    border-radius: 40px;
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 500;
    color: #eb6608;
    cursor: pointer;
    transition: all 0.2s;
    background: #fff;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.chat-option-btn:hover {
    background: #eb6608;
    color: #fff;
    border-color: #eb6608;
}

/* Input area */
.chat-input-area {
    display: flex;
    align-items: center;
    padding: 12px;
    background: #fff;
    border-top: 1px solid #e2e8f0;
    gap: 8px;
}

.chat-input {
    flex: 1;
    border: 1px solid #cbd5e1;
    border-radius: 50px !important;
    padding: 10px 15px;
    font-size: 14px;
    outline: none;
    font-family: inherit;
    margin-bottom: 0 !important;
}

.chat-input:focus {
    border-color: #203669;
}

.send-btn {
    background: #eb6608;
    border: none;
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50px;
    font-weight: bold;
    cursor: pointer;
    font-size: 18px;
    transition: 0.2s;
}

.send-btn:hover {
    background: #203669;
}

/* Form layout inside chat */
.contact-form-fields {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 10px;
}

.contact-form-fields input {
    padding: 10px 12px;
    border-radius: 30px;
    border: 1px solid #ccc;
    font-size: 14px;
    width: 100%;
}

.form-submit-btn {
    background: #1e2a3e;
    color: white;
    border: none;
    padding: 10px;
    border-radius: 40px;
    font-weight: bold;
    cursor: pointer;
    margin-top: 5px;
}

/* small loader */
.loader-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #aaa;
    margin: 0 2px;
    animation: blink 1s infinite;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}