/* ==========================
   FLOATING BOT
========================== */

.chatbot-wrapper{
    position:fixed;
    left:20px;
    bottom:20px;
    z-index:99999;
}

.bot-icon{
    width: 65px;
    height: 65px;
    border-radius:50%;
    cursor:pointer;
    overflow:hidden;
    background:#fff;
    box-shadow:0 10px 25px rgba(0,0,0,.15);
    transition:.3s;
}

.bot-icon:hover{
    transform:scale(1.05);
}

.bot-icon img{
    width:65px;
    height:65px;
    object-fit:cover;
}

/* ==========================
   WELCOME MESSAGE
========================== */

.welcome-message{
    position:absolute;
    bottom:100px;
    left:0;
    width:260px;
    background:#fff;
    padding:14px;
    border-radius:14px;
    border:1px solid var(--color-secondary);
    box-shadow:0 10px 25px rgba(0,0,0,.12);

    opacity:0;
    visibility:hidden;
    transition:.3s;
}

.chatbot-wrapper:hover .welcome-message{
    opacity:1;
    visibility:visible;
}

.welcome-message::after{
    content:'';
    position:absolute;
    bottom:-10px;
    left:25px;

    border-left:10px solid transparent;
    border-right:10px solid transparent;
    border-top:10px solid white;
}

/* ==========================
   BLUR OVERLAY
========================== */

.chat-overlay{
    position:fixed;
    inset:0;

    background:rgba(0,0,0,.25);
    backdrop-filter:blur(8px);

    display:flex;
    justify-content:center;
    align-items:center;

    opacity:0;
    visibility:hidden;

    transition:.3s;
    z-index:99999;
}

.chat-overlay.active{
    opacity:1;
    visibility:visible;
}

/* ==========================
   CHAT MODAL
========================== */

.chat-modal{
    /*width:380px;
    height:700px;

    background:white;
    border-radius:28px;

    overflow:hidden;

    display:flex;
    flex-direction:column;

    box-shadow:
    0 20px 60px rgba(0,0,0,.25);

    animation:popup .25s ease;*/

    width:min(95vw, 420px);
    height:min(90vh, 750px);
    background:white;
    border-radius:28px;
    overflow:hidden;
    display:flex;
    flex-direction:column;
    box-shadow:0 20px 60px rgba(0,0,0,.25);
    animation:popup .25s ease;
}

@keyframes popup{
    from{
        transform:scale(.9);
        opacity:0;
    }
    to{
        transform:scale(1);
        opacity:1;
    }
}

/* ==========================
   HEADER
========================== */

.chat-header{
    background:var(--gradient-header);
    color:white;

    padding:18px;

    display:flex;
    justify-content:space-between;
    align-items:center;
}

.chat-user{
    display:flex;
    align-items:center;
    gap:12px;
}

.chat-user img{
    width:45px;
    height:45px;
    border-radius:50%;
    background:white;
}

.chat-user h4{
    margin:0;
}

.chat-user span{
    font-size:12px;
    opacity:.8;
}

#closeModal, #resetChat{
    width:36px;
    height:36px;

    border:none;
    border-radius:50%;

    background:rgba(255,255,255,.15);

    color:white;
    cursor:pointer;
}

/* ==========================
   BODY
========================== */

.chat-body{
    flex:1;
    padding:20px;
    background:#fafafa;
    overflow-y:auto;
}

.bot-msg{
    max-width:90%;
    background:white;
    padding:12px 16px;
    font-size:14px;
    line-height:1.6;
    border-radius:18px;
    border-bottom-left-radius: 5px;
    box-shadow:0 3px 10px rgba(0,0,0,.08);
}

/* ==========================
   FOOTER
========================== */

.chat-footer{
    padding:15px;
    display:flex;
    gap:10px;
    border-top:1px solid #eee;
    align-items:flex-end;
}

.chat-footer input{
    flex:1;
    font-size:15px;
    line-height:1.4;
    border:1px solid #ddd;
    border-radius:30px;
    padding:12px 18px;
    outline:none;
}

.chat-footer textarea{
    flex:1;
    border:1px solid #ddd;
    border-radius:20px;
    padding:12px 16px;
    resize:none;
    outline:none;
    font-size:14px;
    line-height:1.5;
    min-height:48px;
    max-height:120px;
    overflow-y:auto;
}

.chat-footer button, .resetChatHome{
    /*min-width:80px;*/
    height: 45px;
    border:none;
    border-radius:30px;
    padding:0 17px;
    cursor:pointer;
    color:white;
    font-size:14px;
    font-weight:800;
    background:var(--gradient-button);
}

.user-msg-wrapper{
    display:flex;
    justify-content:flex-end;
    margin-bottom:12px;
}

.user-msg{
    max-width:85%;
    background: var(--gradient-orange);;
    color:#fff;
    line-height:1.5;
    padding:12px 16px;
    border-radius:18px;
    border-bottom-right-radius: 5px;
    word-break:break-word;
}

.bot-msg-wrapper{
    display:flex;
    gap:10px;
    margin:12px 0;
}

.typing-indicator{
    display:flex;
    gap:5px;
}

.typing-indicator span{
    width:8px;
    height:8px;
    border-radius:50%;
    background:#999;
    animation:typing 1s infinite;
}

.typing-indicator span:nth-child(2){
    animation-delay:.2s;
}

.typing-indicator span:nth-child(3){
    animation-delay:.4s;
}

@keyframes typing{
    0%,100%{
        opacity:.3;
    }
    50%{
        opacity:1;
    }
}

/* Close Confirmation Modal */

.close-confirm-modal{
    position:fixed;
    top:0;
    left:0;
    width:100%;
    height:100%;

    display:none;
    justify-content:center;
    align-items:center;
    background:rgba(0,0,0,.35);
    backdrop-filter:blur(4px);
    z-index:100000;
}

.close-confirm-modal.active{
    display:flex;
}

.close-confirm-card{

    width:90%;
    max-width:320px;
    background:#fff;
    border-radius:24px;
    padding:25px;
    text-align:center;
    animation:popup .25s ease;
}

.confirm-icon{
    font-size:40px;
    margin-bottom:10px;
}

.close-confirm-card h4, .close-confirm-card .h4{
    margin-bottom:10px;
    font-weight:600;
    font-size: 1.5rem;
    color: var(--bs-heading-color);
}

.close-confirm-card p{
    font-size:14px;
    color:#666;
    margin-bottom:20px;
}
.confirm-actions{
    display:flex;
    gap:10px;
}

.btn-cancel,
.btn-close-chat{
    flex:1;
    border:none;
    height:44px;
    border-radius:12px;
    cursor:pointer;
    font-weight:600;
}

.btn-cancel{
    background:#f3f4f6;
}

.btn-close-chat{
    color:#fff;
    background:var(--gradient-button);
}

/* New API UI*/
.message-content {
    display: inline-block;
    max-width: 90%;
    padding: 12px 18px;
    border-radius: 20px;
    font-size: 14px;
    line-height: 1.5;
    word-wrap: break-word;
}

.message_bot .message-content {
    background: white;
    color: #333;
    border-bottom-left-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    margin-bottom:10px;
}

.message.user .message-content {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-bottom-right-radius: 5px;
}

.option-buttons {
    display: flex;
    gap: 5px;
    /*margin-top: 15px;*/
    flex-wrap: wrap;
}

.option-btn {
    padding: 6px 8px;
    background: white;
    border: 1px solid #8e355e ;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 14px;
    color: #8e355e ;
    font-weight: 500;
    font-family: inherit;
}

.option-btn:hover {
    background: var(--gradient-button);;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102,126,234,0.3);
}

.option-btn.skip-btn {
    background: #f0f0f0;
    border-color: #999;
    color: #666;
}

.option-btn.skip-btn:hover {
    background: #999;
    color: white;
}

.option-btn.yd-btn {
    background: linear-gradient(90deg, #61F4DE, #6E78FF);
    border-color: #6e78ff;
    color: white;
}

.option-btn.yd-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(17,153,142,0.4);
}

.option-btn.city-option {
    background: #fff3e0;
    border-color: #ff9800;
    color: #e65100;
    font-weight: 600;
}

.option-btn.city-option:hover {
    background: #ff9800;
    color: white;
    box-shadow: 0 5px 15px rgba(255,152,0,0.3);
}


.bot-package-card {
    background: white;
    padding: 15px;
    margin: 10px 0;
    min-width: 220px;
    border-radius: 15px;
    border: 2px solid #953561;
    box-shadow: 0 2px 10px rgba(106, 0, 49, 0.08);
    transition: all 0.3s;
}

.bot-package-card:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 20px rgba(106, 0, 49, 0.12);
}

.bot-package-name {
    font-size: 16px;
    font-weight: bold;
    color: #6a0031;
    margin-bottom: 8px;
}

.bot-package-img{
    width:100%;
    height:130px;
    overflow:hidden;
    border-radius:14px 14px 0 0;
}

.bot-package-img img{
    width:100%;
    height:100%;
    object-fit:cover;
    display:block;
}

.bot-package-details {
    font-size: 13px;
    color: #555;
    margin: 5px 0;
}

.bot-package-cards{
    display: flex;
    gap: 12px;
    justify-content: flex-start;
    max-width: 100%;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 5px 2px 12px;
}

.bot-package-link {
    display: inline-block;
    margin-top: 10px;
    color: #953561;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    transition: color 0.3s;
}

.bot-package-link:hover {
    color: #6a0031;
    text-decoration: underline;
}

.contact-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
    flex-wrap: wrap;
}

.contact-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
}

.contact-btn.call {
    background: #28a745;
    color: white;
}

.contact-btn.call:hover {
    background: #218838;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(40,167,69,0.3);
}

.contact-btn.whatsapp {
    background: #25d366;
    color: white;
}

.contact-btn.whatsapp:hover {
    background: #1da851;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(37,211,102,0.3);
}

.contact-btn.website {
    background: linear-gradient(225deg, #953561 0%, #6a0031 100%);
    color: white;
}

.contact-btn.website:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(149, 53, 97, 0.3);
}

.recommendation {
    background: #fff0f5;
    padding: 15px;
    border-radius: 10px;
    border-left: 4px solid #953561;
    margin: 10px 0;
    font-size: 14px;
    color: #6a0031;
}

.text-input-container {
    margin-top: 10px;
    display: flex;
    gap: 10px;
}

.text-input {
    flex: 1;
    padding: 10px;
    border: 2px solid #e0e0e0;
    border-radius: 20px;
    font-size: 14px;
    outline: none;
    font-family: inherit;
}

.text-input:focus {
    border-color: #ff8f57;
}

.text-submit {
    padding: 10px 20px;
    background:  var(--gradient-button);
    color: white;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 500;
}

.text-submit:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 15px rgba(149, 53, 97, 0.3);
}

.city-input-container {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: #fff8e1;
    padding: 15px;
    border-radius: 12px;
    border: 1px dashed #ff9800;
}

.city-input-group {
    display: flex;
    gap: 5px;
    align-items: center;
}

.city-input {
    flex: 1;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 25px;
    font-size: 14px;
    outline: none;
    font-family: inherit;
}

.city-input:focus {
    border-color: #ff9800;
    box-shadow: 0 0 0 3px rgba(255,152,0,0.2);
}

.city-input-container p {
    color: #6a0031 !important;
    font-weight: 500;
}

.divider {
    margin: 10px 0;
    text-align: center;
    position: relative;
}

.divider::before,
.divider::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 40%;
    height: 1px;
    background: #e0e0e0;
}

.divider::before {
    left: 0;
}

.divider::after {
    right: 0;
}

.divider span {
    background: #f5f5f5;
    padding: 0 10px;
    color: #999;
    font-size: 12px;
}

.city-label {
    font-size: 13px;
    color: #666;
    margin-top: 5px;
    font-style: italic;
}

.city-hint {
    font-size: 12px;
    color: #999;
    margin-top: 5px;
}


/*New API UI End*/
/* ==========================
   TABLET
========================== */

/*@media(max-width:768px){

    .chat-modal{
        width:90%;
        max-width:400px;
        height:85vh;
    }
}*/

/* ==========================
   MOBILE
========================== */

@media(max-width:576px){

    .chat-overlay{
        align-items:flex-end;
    }

    .chat-modal{
        width:100%;
        height:100vh;
        border-radius:24px 24px 0 0;
    }

    .bot-icon, .bot-icon img{
        width:60px;
        height:60px;
    }
    .welcome-message{
        width:220px;
        bottom: 80px
    }
    .chat-header{
        padding-top:calc(18px + env(safe-area-inset-top));
    }
    .bot-msg,.user-msg {

        font-size:15px;
        line-height:1.6;
        max-width:90%;
    }
    .chat-footer input{
        font-size:16px;
    }

}
