/* [File: public/css/chat-style.css - 100% UPDATED VERSION (Width Fixed)] */

/* 1. THEME VARIABLES */
:root {
    --yale-blue: #1B4079;
    --air-force-blue: #0d6e8b;
    --mindaro-accent: #d2fa5c;
    --dark-blue-bg: #0A192F;
    --max-width: 900px; /* <--- YEH BADLA HAI (1000px se 900px) */

    /* Light Mode Palette */
    --bg-main: #f4f7f9;
    --bg-content: #FFFFFF;
    --text-primary: #111111;
    --text-secondary: #555555;
    --border-color: #e5e5e5;
    --sidebar-bg: var(--yale-blue);
    --sidebar-text: #FFFFFF;
    --bg-secondary: #F0F2F5; /* Added for contact page */
    
    /* [!!! NEW VARS ADDED !!!] */
    --card-background: #FFFFFF;
    --dark-card-background: #1c2536;
    --dark-chat-bubble-ai: #1d2b40;
    --dark-border-color: #2a3b59;
    --text-muted: #8899a6;
    --background-secondary: #f0f2f5;
    --primary-color: var(--yale-blue); /* Alias for consistency */
    --primary-hover: #163561;
    --text-light: #FFFFFF;
}

.dark-mode {
    /* Dark Mode Palette */
    --bg-main: var(--dark-blue-bg);
    --bg-content: #1e1e1e; /* This is an old var, new ones are more specific */
    --text-primary: #e5e5e5;
    --text-secondary: #bbbbbb;
    --border-color: #333333; /* Old var */
    --sidebar-bg: #051021;
    --bg-secondary: #1A2A44; /* Added for contact page */
    
    /* [!!! NEW VARS ADDED !!!] */
    --card-background: var(--dark-card-background);
    --border-color: var(--dark-border-color); /* Overriding old border-color */
    --text-muted: #8899a6;
    --background-secondary: #1a2a44;
    --primary-color: var(--mindaro-accent); /* Alias for consistency */
    --primary-hover: #b8cc81;
}

/* 2. GENERAL STYLES */
html, body {
    height: 100%;
    margin: 0;
    font-family: Arial, sans-serif;
    background-color: var(--bg-main);
    color: var(--text-primary);
    overflow: hidden;
    transition: background-color 0.3s, color 0.3s;
}

/* 3. THEME TOGGLE & SIDEBAR */
.theme-toggle {
    background: none; border: none; font-size: 1.2rem; cursor: pointer; position: relative; width: 24px; height: 24px;
}
.theme-toggle.top-right { position: fixed; top: 15px; right: 15px; z-index: 1001; }
.theme-toggle .fa-sun { color: #f39c12; }
.theme-toggle .fa-moon { color: #f1c40f; }
.theme-toggle i { position: absolute; top: 0; left: 0; transition: transform 0.3s, opacity 0.3s; }
.dark-mode .theme-toggle .fa-sun { transform: scale(0); opacity: 0; }
.dark-mode .theme-toggle .fa-moon { transform: scale(1); opacity: 1; }
.dark-mode .theme-toggle .fa-moon:hover { text-shadow: 0 0 10px var(--mindaro-accent); }
body:not(.dark-mode) .theme-toggle .fa-sun { transform: scale(1); opacity: 1; }
body:not(.dark-mode) .theme-toggle .fa-sun:hover { text-shadow: 0 0 10px var(--yale-blue); }
body:not(.dark-mode) .theme-toggle .fa-moon { transform: scale(0); opacity: 0; }
.sidebar {
    position: fixed; top: 0; left: -280px; width: 280px; height: 100%;
    background-color: var(--sidebar-bg); color: var(--sidebar-text);
    padding: 20px; box-sizing: border-box;
    transition: left 0.3s ease-in-out; z-index: 1000;
    
    display: flex;
    flex-direction: column; 
    justify-content: flex-start;
}
body.sidebar-open .sidebar { left: 0; }
.sidebar .logo { color: var(--sidebar-text); font-size: 1.5rem; font-weight: bold; text-decoration: none; margin-bottom: 30px; }
.sidebar-nav ul { list-style: none; padding: 0; margin: 0; }
.sidebar-nav li a { color: var(--sidebar-text); text-decoration: none; display: block; padding: 10px 0; font-size: 1.1rem; }
.burger-menu {
    position: fixed; top: 15px; left: 15px;
    background: none; border: none; font-size: 2rem;
    cursor: pointer; z-index: 999; color: var(--text-primary);
}
.dark-mode .burger-menu { color: var(--text-light); }



/* ========================================================= */
/* 3. CHAT SIDEBAR (FINAL UPDATED STYLE)                     */
/* ========================================================= */

/* --- Burger Menu Button (Trigger) --- */
.burger-menu {
    position: fixed; 
    top: 15px; 
    left: 15px;
    background: none; 
    border: none; 
    font-size: 1.8rem;
    cursor: pointer; 
    z-index: 100; 
    color: var(--text-primary);
    transition: color 0.3s ease, opacity 0.3s ease; /* Opacity transition added */
    padding: 5px;
}
.dark-mode .burger-menu { 
    color: var(--text-light); 
}

/* --- HIDE BURGER WHEN SIDEBAR IS OPEN --- */
body.sidebar-open .burger-menu {
    opacity: 0;
    pointer-events: none; /* Click na ho sake */
}

/* --- Sidebar Panel --- */
.sidebar {
    position: fixed; 
    top: 0; 
    left: 0; 
    transform: translateX(-100%); 
    width: 280px; 
    height: 100vh;
    /* BACKGROUND COLOR UPDATED: यह चैट पेज के बैकग्राउंड से थोड़ा हल्का होगा */
    background-color: var(--bg-sidebar-light); /* नया CSS वेरिएबल इस्तेमाल किया */
    box-shadow: 5px 0 25px rgba(0,0,0,0.2);
    z-index: 1100; 
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    padding: 20px;
    box-sizing: border-box;
    overflow-y: auto;
}

body.sidebar-open .sidebar {
    transform: translateX(0); 
}

/* --- Overlay --- */
.sidebar-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 1050; 
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease;
    backdrop-filter: blur(2px);
}
body.sidebar-open .sidebar-overlay {
    opacity: 1;
    visibility: visible;
}

/* --- Close Button --- */
.close-sidebar-btn {
    align-self: flex-end; 
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 5px;
    line-height: 1;
    margin-bottom: 20px;
}
.close-sidebar-btn:hover {
    color: var(--air-force-blue);
    transform: rotate(90deg);
    transition: transform 0.3s ease;
}

/* --- Logo --- */
.sidebar .logo {
    display: block;
    text-align: center;
    margin-bottom: 20px;
}
.sidebar .logo a {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none; /* अंडरलाइन हटा दें */
}
.sidebar .logo img {
    height: 40px; /* आपके लोगो की ऊंचाई के अनुसार एडजस्ट करें */
    width: auto;
    margin-right: 10px; /* लोगो और टेक्स्ट के बीच गैप */
    /* DEFAULT में लाइट लोगो दिखाएं, डार्क मोड में dark लोगो दिखाएं */
    display: block; /* हमेशा visible */
}
/* अगर आपके पास dark mode के लिए अलग लोगो है */
body.dark-mode .sidebar .logo img.logo-light {
    display: none; /* डार्क मोड में लाइट लोगो छिपाएं */
}
body.dark-mode .sidebar .logo img.logo-dark {
    display: block; /* डार्क मोड में डार्क लोगो दिखाएं */
}
/* --- Navigation Links --- */
.sidebar-nav ul { 
    list-style: none; padding: 0; margin: 0; width: 100%;
}
.sidebar-nav li {
    width: 100%;
    border-bottom: 1px solid var(--border-color);
}
.sidebar-nav li a { 
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 10px;
    text-decoration: none;
    font-size: 1.1rem;
    color: var(--text-primary);
    font-weight: 600;
    transition: background-color 0.2s ease, color 0.2s ease;
}
.sidebar-nav li a i {
    width: 25px;
    text-align: center;
    color: var(--air-force-blue);
}
.sidebar-nav li a:hover {
    background-color: var(--bg-main);
    color: var(--air-force-blue);
    padding-left: 20px; 
}

/* --- Auth Section (Spacing) --- */
.sidebar-auth-footer {
    margin-top: 10px; /* Thoda gap list se */
}

/* --- Greeting Text --- */
.sidebar-greeting {
    font-weight: bold;
    color: var(--air-force-blue);
    padding: 10px 10px;
    margin: 0;
    font-size: 1.1rem;
    border-bottom: 1px solid var(--border-color);
}

/* --- AUTH LINKS (SIMPLE STYLE - NO BUTTONS) --- */
.sidebar-action-btn {
    display: flex !important;
    align-items: center;
    gap: 15px;
    padding: 15px 10px;
    text-decoration: none;
    font-size: 1.1rem; /* Font size match karaya */
    color: var(--text-primary) !important; /* Theme color lega */
    font-weight: 600;
    border: none !important;
    background: none !important;
    width: 100%;
    box-sizing: border-box;
    margin: 0 !important;
    border-bottom: 1px solid var(--border-color) !important; /* Separator line */
}

.sidebar-action-btn i {
    width: 25px;
    text-align: center;
    color: var(--air-force-blue);
}

.sidebar-action-btn:hover {
    background-color: var(--bg-main) !important;
    color: var(--air-force-blue) !important;
    padding-left: 20px; /* Slide Effect */
}

/* Logout Red Style */
#sidebar-logout-btn {
    color: #e74c3c !important;
}
#sidebar-logout-btn i {
    color: #e74c3c !important;
}

/* ========================================================= */
/* FIXES 1 & 2: LOGO VISIBILITY & SEPARATOR CLUTTER          */
/* ========================================================= */

/* --- LOGO VISIBILITY FIX (If two image tags are used) --- */
/* Default (Light Mode) */
.sidebar .logo img.logo-dark {
    display: none !important; /* Dark logo को छिपाए */
}
.sidebar .logo img.logo-light {
    display: block !important; /* Light logo को दिखाए */
}
/* Dark Mode Override */
.dark-mode .sidebar .logo img.logo-dark {
    display: block !important; /* Dark mode में Dark logo दिखाए */
}
.dark-mode .sidebar .logo img.logo-light {
    display: none !important; /* Dark mode में Light logo छिपाए */
}

/* --- SEPARATOR LINE FIXES (Clutter Remove) --- */

/* 1. Main Navigation List (Privacy के नीचे की Line हटाना) */
.sidebar-nav ul li:last-child {
    border-bottom: none !important;
}

/* 4. CHAT AREA & STATIC PREVIEW PAGE STYLES */
.chat-window {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 30px;
    height: 100vh;
    box-sizing: border-box;
    overflow-y: auto;
	padding-bottom: 150px; /* Desktop ke liye extra padding */
    -ms-overflow-style: none;
    scrollbar-width: none;
}
.chat-window::-webkit-scrollbar {
    display: none;
}
.welcome-message {
    text-align: center; background: transparent; border: none;
    margin: auto; max-width: 100%;
}
.welcome-heading { font-size: 2rem; color: var(--yale-blue); margin-bottom: 5px; }
.dark-mode .welcome-heading { color: var(--mindaro-accent); }
.welcome-tagline { font-size: 1.1rem; color: var(--text-secondary); margin-top: 0; }

.trip-summary-card, .destination-overview-card, .itinerary-display-card {
    background-color: var(--bg-content);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 25px 40px;
    margin-bottom: 30px;
    width: 100%;
    max-width: var(--max-width);
    box-sizing: border-box;
}
.dark-mode .trip-summary-card, 
.dark-mode .destination-overview-card, 
.dark-mode .itinerary-display-card {
    background-color: var(--dark-card-background); /* [!!! UPDATED !!!] */
    border-color: var(--border-color); /* [!!! UPDATED !!!] */
}
.trip-summary-card h3 {
    margin-top: 0; font-size: 1.5rem; color: var(--yale-blue);
    border-bottom: 1px solid var(--border-color); padding-bottom: 10px;
}
.dark-mode .trip-summary-card h3 { color: var(--mindaro-accent); }
.summary-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 20px; margin: 20px 0; }
.summary-item { display: flex; flex-direction: column; }
.summary-item strong { font-size: 0.9rem; color: var(--text-secondary); text-transform: uppercase; margin-bottom: 5px; display: flex; align-items: center; gap: 5px; }
.summary-item span { font-size: 1.1rem; font-weight: bold; text-transform: capitalize; }
.summary-interests { margin-top: 10px; }
.summary-interests strong { font-size: 0.9rem; color: var(--text-secondary); text-transform: uppercase; margin-right: 10px; }
.interest-tag { display: inline-block; background-color: var(--air-force-blue); color: #fff; padding: 5px 10px; border-radius: 15px; font-size: 0.9rem; margin: 5px 5px 5px 0; }
.destination-overview-card h2 { margin-top: 0; }

/* 5. ITINERARY DISPLAY STYLES */
.itinerary-main-title { font-size: 2rem; text-align: center; } /* Added title style */
.itinerary-display-card h3 { font-size: 1.5rem; margin-top: 20px; }
.destination-overview-card h3 { font-size: 1.5rem; margin-top: 0; }

.itinerary-day { font-size: 1.6rem; color: var(--mindaro-accent); border-bottom: 2px solid var(--air-force-blue); padding-bottom: 8px; margin-top: 25px; margin-bottom: 5px; background-color: transparent; border-radius: 0; }
body:not(.dark-mode) .itinerary-day { color: var(--yale-blue); }
.map-link { display: inline-block; margin: 5px 0 15px 5px; font-size: 0.9rem; color: var(--air-force-blue); text-decoration: none; font-weight: bold; }
.map-link:hover { text-decoration: underline; }
.map-link i { margin-right: 5px; }
.itinerary-period { font-size: 0.9rem; color: var(--text-secondary); text-transform: uppercase; font-weight: 600; margin-top: 20px; margin-bottom: 10px; }
.itinerary-display-card ul, .destination-overview-card ul { list-style: none; padding-left: 5px; margin: 0; }
/* .itinerary-activity styles moved to a dedicated section below */
.itinerary-actions { margin-top: 25px; display: flex; flex-wrap: wrap; gap: 10px; }
.action-btn { flex-grow: 1; padding: 10px; border-radius: 6px; border: 1px solid var(--air-force-blue); background: none; color: var(--air-force-blue); cursor: pointer; font-weight: bold; transition: all 0.3s; font-size: 1rem; }
.action-btn.book-btn { background: var(--air-force-blue); color: #fff; }
.action-btn:hover { opacity: 0.8; }

/* 6. CHAT INPUT & FOOTER */
.chat-form-wrapper { position: fixed; bottom: 0; left: 0; right: 0; width: 100%; background-color: var(--bg-main); z-index: 10; border-top: 1px solid var(--border-color); }
.chat-form { padding: 10px; max-width: var(--max-width); margin: 0 auto; }
.input-wrapper { position: relative; width: 100%; }
#chat-input { width: 100%; border: 1px solid var(--border-color); border-radius: 8px; padding: 15px 50px 15px 20px; font-size: 1rem; background-color: var(--bg-main); color: var(--text-primary); box-sizing: border-box; }
#chat-input:focus { border-color: var(--air-force-blue); outline: none; }
.send-icon-button { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); background: none; border: none; color: var(--air-force-blue); font-size: 1.2rem; cursor: pointer; padding: 5px; transition: color 0.3s, transform 0.2s; }
.send-icon-button:hover { color: #5a9aaa; transform: translateY(-50%) scale(1.1); }
.chat-footer { text-align: center; padding-bottom: 10px; font-size: 0.8rem; color: #888; }
.chat-footer a { color: #888; text-decoration: none; font-weight: bold; }
.chat-footer a:hover { text-decoration: underline; }

/* 7. MODAL STYLES (Trip & Share) */
.modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background-color: rgba(10, 25, 47, 0.7);
    display: none; justify-content: center; align-items: center;
    z-index: 2000; opacity: 0; transition: opacity 0.3s ease; backdrop-filter: blur(5px);
}
.modal-content {
    position: relative; background-color: var(--bg-content); color: var(--text-primary);
    padding: 30px; border-radius: 12px; width: 90%; max-width: 500px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2); transform: scale(0.9); transition: transform 0.3s ease;
    border-top: 5px solid var(--air-force-blue);
}
.dark-mode .modal-content { background-color: var(--dark-card-background); border-color: var(--border-color); } /* [!!! UPDATED !!!] */
.close-modal-btn {
    position: absolute; top: 10px; right: 10px; background: var(--bg-content);
    border: 1px solid var(--border-color); width: 30px; height: 30px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center; font-size: 1rem;
    color: var(--text-secondary); cursor: pointer; transition: all 0.3s;
}
.close-modal-btn:hover { color: var(--yale-blue); transform: rotate(90deg) scale(1.1); border-color: var(--yale-blue); }
.dark-mode .close-modal-btn:hover { color: var(--mindaro-accent); border-color: var(--mindaro-accent); }
.modal-overlay.visible { display: flex; opacity: 1; }
.modal-overlay.visible .modal-content { transform: scale(1); }
.modal-content h2 { margin-top: 0; color: var(--yale-blue); }
.dark-mode .modal-content h2 { color: var(--mindaro-accent); }
.modal-content p { margin-bottom: 20px; color: var(--text-secondary); }
#details-form label, #user-details-form label { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; font-weight: bold; }
#details-form input, #details-form select, #details-form textarea,
#user-details-form input { 
    width: 100%; padding: 12px; border: 1px solid var(--border-color); background-color: var(--bg-main); color: var(--text-primary); 
    border-radius: 6px; box-sizing: border-box; margin-bottom: 15px; font-family: inherit; font-size: 1rem;
}
.radio-group, .checkbox-group { display: flex; flex-wrap: wrap; gap: 15px; margin-bottom: 15px; border: 1px solid var(--border-color); padding: 10px; border-radius: 6px; }
.radio-group label, .checkbox-group label { display: flex; align-items: center; gap: 5px; font-weight: normal; }
.generate-button { width: 100%; padding: 12px; background-color: var(--air-force-blue); color: #FFFFFF; border: none; border-radius: 6px; font-size: 1.1rem; font-weight: bold; cursor: pointer; transition: background-color 0.3s ease; }
.generate-button:hover { background-color: #5a9aaa; }
.form-row { display: flex; gap: 15px; }
.form-group { flex: 1; }
#details-form textarea { resize: vertical; }

/* 8. SHARE MODAL SPECIFIC STYLES */
.share-options-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; margin-top: 20px; }
.share-option-btn { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 20px; font-size: 1rem; font-weight: bold; color: var(--text-primary); background-color: var(--bg-main); border: 1px solid var(--border-color); border-radius: 8px; cursor: pointer; transition: all 0.3s ease; }
.share-option-btn:hover { border-color: var(--air-force-blue); color: var(--air-force-blue); transform: translateY(-3px); }
.share-option-btn i { font-size: 2rem; color: var(--air-force-blue); }
#user-details-view form { margin-top: 20px; }

#share-options-view.details-required .share-option-btn {
    opacity: 0.6;
    cursor: not-allowed;
}
#share-options-view.details-required .share-option-btn:hover {
    transform: none;
    border-color: var(--border-color);
    color: var(--text-primary);
}


/* 9. MOBILE RESPONSIVENESS */
@media (max-width: 768px) {
    
    html, body {
        overflow-y: auto !important;   /* Scroll ko force enable karein */
        overflow-x: hidden !important;
        height: auto;
        min-height: 100vh;
    }
 
    /* --- [FIXED] Bottom padding badha di gayi hai --- */
    .chat-window { 
        padding: 60px 20px 120px; /* 50px se 120px kiya gaya */
    }
    
    .trip-summary-card, .destination-overview-card, .itinerary-display-card { padding: 15px 20px; }
    .burger-menu { font-size: 1.5rem; }
    
    /* Sidebar ko mobile par responsive banayein */
    .sidebar {
        width: 250px; /* Thoda patla */
        left: -250px;
    }
    body.sidebar-open .chat-container {
        transform: translateX(250px);
    }
    .chat-container {
        transition: transform 0.3s ease-in-out;
    }
    
    /* Modal ko mobile par set karein */
    .modal-content {
        width: 90%;
        padding: 20px;
        max-height: 85vh; /* Limit height */
        overflow-y: auto; /* Scroll agar zaroorat ho */
        overflow-x: hidden;
    }
    
    .form-row {
        flex-direction: column; /* Form fields ko stack karein */
        gap: 0;
    }
    .form-group {
        margin-bottom: 15px;
    }
}

 
/* ========================================================= */
/* == RADIO/CHECKBOX FIX                                 == */
/* ========================================================= */

.radio-group label,
.checkbox-group label {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important; 
    margin-bottom: 15px !important;
    cursor: pointer !important;
    font-size: 16px !important;
}

.radio-group input[type="radio"],
.checkbox-group input[type="checkbox"] {
    appearance: none !important;
    -webkit-appearance: none !important;
    margin: 0 !important; 
    width: 15px !important;  
    height: 15px !important; 
    border: 2px solid #5a5a5a !important;
    transition: all 0.2s ease-in-out !important;
    flex-shrink: 0 !important;
    position: relative !important;
    background-color: transparent !important; 
}

.radio-group input[type="radio"] {
    border-radius: 50% !important;
}

.checkbox-group input[type="checkbox"] {
    border-radius: 3px !important; 
}

.radio-group input[type="radio"]:checked {
    border-color: #007bff !important;
}

.radio-group input[type="radio"]:checked::before {
    content: '' !important;
    display: block !important;
    width: 8px !important;   
    height: 8px !important;  
    background-color: #007bff !important;
    border-radius: 50% !important;
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important; /* [FIXED] Syntax error 'impor' */
}

.checkbox-group input[type="checkbox"]:checked {
    border-color: #007bff !important;
    background-color: #007bff !important;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%23fff' d='M6.564.75l-3.59 3.612-1.538-1.55L0 4.26 2.974 7.25 8 2.193z'/%3e%3c/svg%3e") !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
}

/* Styles for the Rate Limit Timer */
.rate-limit-container {
    text-align: center;
    margin: auto;
    padding: 20px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background-color: var(--bg-content);
}
.rate-limit-container h2 {
    font-size: 1.5rem;
    color: var(--yale-blue);
}
.dark-mode .rate-limit-container h2 {
    color: var(--mindaro-accent);
}
.timer-countdown {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--air-force-blue);
    margin-top: 10px;
}


/* === PRELOADER KE LIYE YEH NAYA CSS ADD KIYA GAYA HAI === */
#preloader-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    width: 100%;
    max-width: var(--max-width); 
    margin: 40px auto; 
    padding: 20px;
    box-sizing: border-box;
}
#preloader-heading {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--text-primary);
}
#preloader-heading #destination-name {
    color: var(--yale-blue);
    font-weight: bold;
}
.dark-mode #preloader-heading #destination-name {
    color: var(--mindaro-accent);
}
#lottie-animation-container {
    width: 150px; 
    height: 150px;
    margin-bottom: 20px;
}
#loading-text-list {
    text-align: left;
    width: 100%;
    max-width: 400px;
}
#loading-text-list .loading-item {
    font-size: 1.1rem;
    margin: 12px 0;
    color: var(--text-secondary);
    display: flex; 
    align-items: center;
}
#loading-text-list .loading-item .icon {
    margin-right: 15px;
    font-size: 1.2rem;
    color: var(--air-force-blue);
    width: 25px; 
    text-align: center;
}



/* === SAVE ITINERARY BUTTON STYLES === */
.action-btn.save-btn {
    border-color: var(--mindaro-accent); 
    color: var(--mindaro-accent);      
}
body:not(.dark-mode) .action-btn.save-btn {
     border-color: var(--yale-blue);
     color: var(--yale-blue);
}
.action-btn.save-btn:hover:not(:disabled) {
    background-color: var(--mindaro-accent); 
    color: var(--dark-blue-bg);          
}
body:not(.dark-mode) .action-btn.save-btn:hover:not(:disabled) {
    background-color: var(--yale-blue);
    color: white;
}
.action-btn.save-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background-color: transparent !important; 
    color: var(--text-secondary) !important; 
    border-color: var(--text-secondary) !important; 
}
.action-btn.save-btn.saved {
    background-color: #2ecc71 !important; 
    border-color: #2ecc71 !important;   
    color: white !important;           
    cursor: default;                   
}
.action-btn.save-btn.saved:hover {
     opacity: 0.9; 
}


/* --- Sidebar Positioning & Auth login Footer --- */
.sidebar-nav {
    flex-grow: 1; 
    padding-bottom: 15px; 
}
.sidebar-auth-footer {
    padding: 20px 0; 
    border-top: 1px solid rgba(255, 255, 255, 0.1); 
}
.sidebar-greeting {
    color: var(--mindaro-accent); 
    font-size: 1.1rem;
    font-weight: bold;
    text-align: center; 
    padding-bottom: 10px;
    margin-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1); 
}
.sidebar-action-btn {
    display: flex;
    align-items: center;
    justify-content: center; 
    gap: 10px;
    padding: 10px 15px;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: bold;
    text-decoration: none;
    margin: 8px 20px; 
    transition: background-color 0.3s, color 0.3s;
    box-sizing: border-box; 
}
.sidebar-action-btn.dashboard-btn {
    background-color: var(--yale-blue); 
    color: var(--text-light); 
}
.sidebar-action-btn.dashboard-btn:hover {
    background-color: #163561; 
}
.sidebar-action-btn.logout-btn {
    background-color: var(--air-force-blue); 
    color: var(--text-light); 
}
.sidebar-action-btn.logout-btn:hover {
    background-color: #426975; 
}
.sidebar-action-btn.login-btn,
.sidebar-action-btn.register-btn {
    border: 1px solid var(--mindaro-accent);
    background: transparent;
    color: var(--mindaro-accent);
}
.sidebar-action-btn.register-btn:hover {
    background: var(--mindaro-accent);
    color: var(--dark-blue-bg, #0A192F); 
}

/* [!!! NEW: System Message Styles !!!] */
.chat-message.system-message {
    text-align: center;
    padding: 5px 0;
    margin: 10px auto;
    width: 100%;
    max-width: var(--max-width);
}
.system-message p {
    display: inline-block;
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: 500;
}
.system-message.success-message p {
    background-color: rgba(46, 204, 113, 0.1);
    color: #2ecc71;
}
.system-message.error-message p {
    background-color: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
}

/* CHAT SUMMARY CARD (Special Request Style) */
.summary-special-request {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px dashed var(--border-color);
    display: flex; 
    align-items: baseline; 
}
.summary-special-request p {
    font-size: 1rem;
    color: var(--text-primary);
    margin-left: 10px; 
    margin-bottom: 0;
    line-height: 1.6;
}

/* ========================================
   ITINERARY MAP LINK STYLES
   ======================================== */

/* दिन के टाइटल के नीचे वाला बड़ा लिंक */
.map-link {
    display: inline-block;
    font-size: 0.9rem;
    color: var(--primary-color);
    text-decoration: none;
    margin-top: 4px;
    margin-bottom: 12px;
    font-weight: 500;
    opacity: 0.9;
    transition: all 0.2s ease;
}

.map-link:hover {
    opacity: 1;
    text-decoration: underline;
}

.map-link i {
    margin-right: 6px;
}

/* ========================================
   ITINERARY ACTIVITY FIX (Flexbox)
   ======================================== */

.itinerary-activity {
    position: relative;
    display: flex; /* Flexbox का उपयोग करें */
    align-items: flex-start; /* आइटम को ऊपर से अलाइन करें */
    margin-bottom: 12px;
    padding-right: 35px; /* मैप बटन के लिए जगह */
    border-bottom: 1px solid var(--border-color);
}

.itinerary-activity > i {
    /* यह आइकन है */
    font-size: 1rem;
    color: var(--text-secondary);
    margin-right: 10px;
    margin-top: 4px; /* टेक्स्ट के साथ अलाइन करने के लिए */
    flex-shrink: 0; /* आइकन को सिकुड़ने न दें */
}

.itinerary-activity .activity-text {
    /* यह टेक्स्ट है (जिसमें <strong> टैग हैं) */
    flex-grow: 1; /* बची हुई जगह ले लें */
    line-height: 1.6;
    color: var(--text-primary);
}

.itinerary-activity .activity-text strong {
    /* <strong> टैग को स्टाइल करें */
    color: var(--primary-color); /* या var(--text-primary) */
    font-weight: 600;
}

.activity-map-link {
    /* Absolute hata diya, ab ye text ke upar nahi chadega */
    position: relative; 
    margin-left: auto; /* Isse icon right side mein chipak jayega */
    margin-top: 2px;   /* Text line ke saath align karne ke liye */
    flex-shrink: 0;    /* Icon sikudega nahi */
    
    /* Styling */
    color: #94a3b8;
    font-size: 1rem;
    padding: 6px;
    border-radius: 50%;
    transition: all 0.2s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: center;
}

.activity-map-link:hover {
    background: #e0f2fe;
    color: #0369a1;
}


/* =================================================================== */
/* === [!!! START: NEW STYLES FOR GENERAL RESPONSE LIST (IMAGE 2) !!!] === */
/* =================================================================== */

/* Pehle purane card styles ko reset karein */
.general-places-grid {
    display: none; /* Purana grid layout hide karein */
}
.general-place-card {
    display: none; /* Purana card layout hide karein */
}

/* Ab naya list-style layout add karein */
.general-query-response {
    background-color: var(--card-background); /* [!!! UPDATED !!!] */
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    animation: fadeIn 0.5s ease-out;
    max-width: var(--max-width); /* <--- YEH NAYA ADD KIYA HAI */
}
.dark-mode .general-query-response {
    background-color: var(--dark-chat-bubble-ai); /* [!!! UPDATED !!!] */
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

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

.general-query-response .general-query-heading {
    color: var(--primary-color);
    font-size: 1.8em;
    margin-top: 0;
    margin-bottom: 10px;
    text-align: center;
    font-weight: 700;
}

.general-query-response .general-intro {
    font-size: 1em;
    line-height: 1.6;
    margin-bottom: 25px;
    text-align: center;
    color: var(--text-secondary);
    border-bottom: 0; /* Remove border from old style */
}

.general-places-container-list-style {
    margin-top: 20px;
}

.general-places-container-list-style .category-heading {
    font-size: 1.4em;
    color: var(--text-primary);
    margin-top: 30px;
    margin-bottom: 15px;
    padding-bottom: 5px;
    border-bottom: 2px solid var(--border-color);
    font-weight: 600;
}
.dark-mode .general-places-container-list-style .category-heading {
    border-bottom-color: var(--dark-border-color);
}

.general-places-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.general-place-list-item {
    background-color: var(--bg-main); /* [!!! UPDATED !!!] */
    border-radius: 10px;
    padding: 15px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease-in-out;
    border: 1px solid var(--border-color);
}
.dark-mode .general-place-list-item {
    background-color: var(--dark-card-background); /* [!!! UPDATED !!!] */
}

.general-place-list-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}
.dark-mode .general-place-list-item:hover {
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}


.list-item-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
}

.place-number {
    background-color: var(--primary-color);
    color: var(--text-light);
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9em;
    font-weight: bold;
    margin-right: 10px;
    flex-shrink: 0;
}
.dark-mode .place-number {
    color: var(--dark-blue-bg); /* Dark text on light accent color */
}


.place-title-wrapper {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    margin-right: 10px;
}

.general-place-list-item h5 {
    font-size: 1.15em;
    margin: 0;
    color: var(--text-primary);
    font-weight: 600;
}

.general-place-list-item .google-rating {
    font-size: 0.85em;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    margin-top: 3px;
}

.general-place-list-item .google-rating i {
    color: #ffc107; /* Google Star color */
    margin-right: 5px;
}

.expand-collapse-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.2em;
    cursor: pointer;
    padding: 5px;
    transition: color 0.2s ease, transform 0.3s ease;
}

.expand-collapse-btn:hover {
    color: var(--primary-color);
}
.expand-collapse-btn.expanded {
    transform: rotate(180deg);
}

.list-item-details-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-out, padding-top 0.4s ease-out, margin-top 0.4s ease-out;
    display: flex; 
    gap: 15px;
    align-items: flex-start;
    padding-top: 0; /* Initially no padding */
    margin-top: 0;
}

.list-item-details-content.expanded {
    max-height: 300px; /* Adjust as needed */
    padding-top: 15px;
    margin-top: 15px; /* Add margin when expanded */
    border-top: 1px solid var(--border-color);
    transition: max-height 0.6s ease-in, padding-top 0.4s ease-in, margin-top 0.4s ease-in;
}

.general-place-thumbnail {
    width: 100px; /* Small image width */
    height: 100px; /* Small image height */
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0; /* Prevent image from shrinking */
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.details-text-wrapper {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.list-item-details-content p {
    margin: 0;
    font-size: 0.95em;
    line-height: 1.5;
    color: var(--text-secondary);
}

.place-category-tag,
.place-time-tag {
    font-size: 0.85em;
    color: var(--text-muted);
}
.place-category-tag strong,
.place-time-tag strong {
    color: var(--text-primary);
}


/* Checkbox styling */
.place-checkbox-wrapper {
    display: flex;
    align-items: center;
    margin-top: 10px;
}

.place-checkbox-wrapper input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border: 2px solid var(--primary-color);
    border-radius: 4px;
    margin-right: 8px;
    cursor: pointer;
    position: relative;
    outline: none;
    background-color: var(--card-background);
    transition: all 0.2s ease;
}
.dark-mode .place-checkbox-wrapper input[type="checkbox"] {
    background-color: var(--dark-card-background);
}


.place-checkbox-wrapper input[type="checkbox"]:checked {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.place-checkbox-wrapper input[type="checkbox"]:checked::after {
    content: '\2713'; /* Checkmark character */
    color: var(--text-light);
    font-size: 14px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}
.dark-mode .place-checkbox-wrapper input[type="checkbox"]:checked::after {
    color: var(--dark-blue-bg);
}


.place-checkbox-wrapper label {
    font-size: 0.95em;
    color: var(--text-secondary);
    cursor: pointer;
}

.cta-book-itinerary-btn {
    width: 100%;
    padding: 12px 20px;
    font-size: 1.1em !important; /* Override .action-btn */
    font-weight: 600;
    margin-top: 30px;
    background-color: var(--primary-color);
    color: var(--text-light);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}
.dark-mode .cta-book-itinerary-btn {
    color: var(--dark-blue-bg);
}

.cta-book-itinerary-btn:hover {
    background-color: var(--primary-hover);
    transform: translateY(-2px);
    opacity: 1 !important; /* Override .action-btn:hover */
    color: var(--text-light) !important;
}
.dark-mode .cta-book-itinerary-btn:hover {
    color: var(--dark-blue-bg) !important;
}


/* Responsive adjustments for new list */
@media (max-width: 768px) {
    .general-query-response {
        padding: 15px;
    }
    .general-query-response .general-query-heading {
        font-size: 1.5em;
    }
    .general-query-response .general-intro {
        font-size: 0.95em;
    }
    .general-places-container-list-style .category-heading {
        font-size: 1.2em;
    }
    .general-place-list-item h5 {
        font-size: 1em;
    }
    .general-place-thumbnail {
        width: 80px;
        height: 80px;
    }
    .list-item-details-content.expanded {
        max-height: 400px; /* Adjust for potentially longer content */
    }
    .cta-book-itinerary-btn {
        font-size: 1em !important;
        padding: 10px 15px;
    }
}

@media (max-width: 480px) {
    .list-item-details-content {
        flex-direction: column; /* Stack image and text vertically */
        align-items: center;
    }
    .general-place-thumbnail {
        margin-bottom: 10px;
        width: 100%;
        height: 150px; /* Taller image on mobile */
    }
    .details-text-wrapper {
        text-align: center;
    }
    .place-checkbox-wrapper {
        justify-content: center;
    }
}

/* == NEW STYLES: General Query Preloader (Image 1)       == */
#general-query-preloader-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    width: 100%;
    max-width: var(--max-width); /* Itinerary preloader jitni hi width */
    margin: 40px auto; 
    padding: 20px;
    box-sizing: border-box;
}

#general-query-preloader-heading {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--text-primary);
}

#general-query-lottie-container {
    width: 150px; /* Same as itinerary preloader */
    height: 150px;
    margin-bottom: 20px;
}

#general-loading-text-list {
    text-align: left;
    width: 100%;
    max-width: 400px; /* Same as itinerary preloader */
}

#general-loading-text-list .loading-item {
    font-size: 1.1rem;
    margin: 12px 0;
    color: var(--text-secondary);
    display: flex; 
    align-items: center;
}

#general-loading-text-list .loading-item .icon {
    margin-right: 15px;
    font-size: 1.2rem;
    color: var(--air-force-blue);
    width: 25px; 
    text-align: center;
}
/* == NEW STYLES: Custom Places Textarea (List View)      == */
.custom-places-wrapper {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px dashed var(--border-color);
}

.custom-places-wrapper label {
    display: block;
    font-size: 1.1em;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.custom-places-wrapper label i {
    color: var(--primary-color);
}

.custom-places-textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    background-color: var(--bg-main);
    color: var(--text-primary);
    border-radius: 6px;
    box-sizing: border-box;
    font-family: inherit;
    font-size: 1rem;
    resize: vertical;
    min-height: 50px;
}

.custom-places-textarea:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 5px rgba(27, 64, 121, 0.3); /* Light mode shadow */
}

.dark-mode .custom-places-textarea {
    background-color: var(--dark-card-background);
}

.dark-mode .custom-places-textarea:focus {
    box-shadow: 0 0 5px rgba(203, 223, 144, 0.3); /* Dark mode shadow */
}

/* Button ke margin ko adjust karein */
.general-query-response .itinerary-actions {
    margin-top: 15px; /* Text box aur button ke beech ka space kam karein */
}
/* =================================================================== */
/* === [!!! END: NEW STYLES !!!] === */
/* =================================================================== */

/* [File: public/css/chat-style.css - YEH CODE AAKHIR MEIN ADD KAREIN] */

/* ========================================================= */
/* == NEW STYLES: Ask Expert Button                       == */
/* ========================================================= */

.ask-expert-btn {
    background: transparent !important; /* Force transparent background */
    border: 1px solid var(--primary-color) !important;
    color: var(--primary-color) !important;
    font-weight: 600;
    text-decoration: none; /* For <a> tag styling */
    text-align: center;
    display: inline-flex; /* To align icon and text */
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 15px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
}

.ask-expert-btn i {
    color: #25D366; /* WhatsApp Green */
}

.ask-expert-btn:hover {
    background-color: var(--primary-color) !important;
    color: var(--text-light) !important;
    opacity: 1 !important;
}

.dark-mode .ask-expert-btn:hover {
    color: var(--dark-blue-bg) !important; /* Dark text on light accent color */
}

.dark-mode .ask-expert-btn:hover i {
    color: var(--dark-blue-bg) !important;
}

.ask-expert-btn:hover i {
    color: var(--text-light) !important;
}

/* Add margin when it's in the itinerary actions */
.itinerary-actions .ask-expert-btn {
    flex-grow: 1;
}

/* Add margin when it's after a factual answer */
.general-query-response .ask-expert-btn {
    margin-top: 20px;
    display: block; /* Make it full width */
    width: 100%;
    box-sizing: border-box; /* Include padding in width */
}

/* --- CAPSULE STYLE FOR ROUTE & DISTANCE --- */
.capsule-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px; /* Buttons ke beech ka space */
    margin-bottom: 15px;
    align-items: center;
}

.capsule-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: 50px; /* Round Capsule Shape */
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none !important;
    white-space: nowrap;
}

/* Map Button Style (Blue) */
.map-capsule {
    background-color: #e3f2fd;
    color: #1565c0;
    border: 1px solid #bbdefb;
    transition: background 0.2s;
}
.map-capsule:hover {
    background-color: #1565c0;
    color: #fff;
}

/* Distance Badge Style (Grey) */
.distance-capsule {
    background-color: #f5f5f5;
    color: #424242;
    border: 1px solid #e0e0e0;
    cursor: default;
}
.distance-capsule i {
    color: #f39c12; /* Orange Car Icon */
}



/* =========================================
   1. ITINERARY TIMELINE DESIGN (Fixed Colors)
   ========================================= */

/* Main Card Container (Outer Box) */
.itinerary-display-card {
    background: #ffffff; /* Light Mode default */
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    margin-top: 20px;
    border: 1px solid #f0f0f0;
    position: relative;
    overflow: visible !important; 
    color: #334155; /* Light Mode Text Color */
}

/* --- DARK MODE for Container (Fixed White Text) --- */
body.dark-mode .itinerary-display-card {
    background: #1e293b; /* Dark Navy Background */
    border-color: #334155;
    box-shadow: none;
    color: #e2e8f0; /* [FIX] Yeh line add ki hai: Text ko White karne ke liye */
}

/* Vertical Line (The Timeline) */
.itinerary-display-card ul {
    border-left: 2px dashed #cbd5e1; /* Light Grey Line */
    margin-left: 5px;
    padding-left: 25px;
    list-style: none;
}

/* Dark Mode Line - White/Light */
body.dark-mode .itinerary-display-card ul {
    border-left-color: rgba(255, 255, 255, 0.2); /* Dotted line visible hogi */
}

/* Day Header (Dot & Title) */
.itinerary-day {
    position: relative;
    font-size: 1.4rem;
    color: #1e293b; /* Light Mode: Dark Text */
    margin-top: 30px;
    margin-bottom: 15px;
    padding-left: 25px;
    font-weight: 800;
}

/* Dark Mode Day Title */
body.dark-mode .itinerary-day {
    color: #f1f5f9 !important; /* [FIX] Force White Text */
}

/* General Text Inside Itinerary (Paragraphs) */
body.dark-mode .itinerary-display-card p {
    color: #e2e8f0; /* Paragraphs bhi white honge */
}
/* The Blue Dot on the Timeline */
.itinerary-day::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 14px;
    height: 14px;
    background-color: #3b82f6; /* Bright Blue */
    border-radius: 50%;
    box-shadow: 0 0 0 4px #e0f2fe;
}

body.dark-mode .itinerary-day::before {
    background-color: #60a5fa; /* Lighter Blue in Dark Mode */
    box-shadow: 0 0 0 4px rgba(96, 165, 250, 0.2);
}

/* --- TIME PERIOD (Morning, Afternoon) - LIME GREEN --- */
.itinerary-period {
    color: #64748b; /* Default Grey */
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 25px;
    margin-bottom: 10px;
    padding-left: 0; /* Align correctly */
    font-weight: 800;
    display: flex;
    align-items: center;
}

/* !!! MAGIC COLOR CHANGE (IMAGE LOOK) !!! */
body.dark-mode .itinerary-period {
    color: #bef264; /* LIME GREEN (Neon) - Jaise Image mein hai */
    text-shadow: 0 0 10px rgba(190, 242, 100, 0.2); /* Slight Glow */
}

/* Individual Activity Item (The White Box) */
.itinerary-activity {
    margin-bottom: 15px;
    padding: 15px 18px;
    background: #f8fafc; /* Light Grey Box */
    border-radius: 10px;
    transition: transform 0.2s ease, background 0.2s;
    font-size: 0.95rem;
    color: #334155;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    border: 1px solid transparent;
}


/* Dark Mode Activity Item */
body.dark-mode .itinerary-activity {
    background: transparent !important; /* White background removed */
    box-shadow: none !important;        /* Shadow removed */
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1); /* Halki line separator ke liye */
    border-radius: 0;
    margin-bottom: 10px;
    padding: 15px 0; /* Side padding hata di taaki clean lage */
}

/* Text Color Fix (Ab background dark hai to text white chahiye) */
body.dark-mode .itinerary-activity .activity-text {
    color: #e2e8f0 !important; /* Light Text */
}

/* Strong Text (Place Names) - Lime Green Highlight */
body.dark-mode .itinerary-activity strong {
    color: #bef264 !important; /* Neon Green Highlight */
    font-weight: 700;
}

/* Icons Fix */
body.dark-mode .itinerary-activity > i {
    color: #60a5fa !important; /* Light Blue Icon */
}

/* =========================================
   2. DESTINATION OVERVIEW & HOTELS
   ========================================= */

.destination-overview-card {
    background: #fff;
    border-left: 5px solid #bef264; /* Lime Green Line */
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

body.dark-mode .destination-overview-card {
    background: #1e293b; /* Dark Background */
    color: #e2e8f0;
    border: 1px solid #334155;
    border-left: 5px solid #bef264; /* Keep Lime Line */
}

.overview-item {
    background: rgba(241, 245, 249, 0.5);
    padding: 10px;
    border-radius: 8px;
    margin-bottom: 8px;
}

body.dark-mode .overview-item {
    background: rgba(255, 255, 255, 0.05); /* Transparent White */
    color: #f1f5f9;
}

/* Hotel Cards */
.hotel-option {
    background: linear-gradient(135deg, #ffffff 0%, #f9faff 100%);
    border: 1px solid #e2e8f0;
    padding: 15px;
    border-radius: 12px;
    color: #334155;
}

body.dark-mode .hotel-option {
    background: #1e293b;
    border-color: #475569;
    color: #f1f5f9;
}

/* =========================================
   3. CAPSULE BUTTONS FIX
   ========================================= */
.capsule-row {
    padding-left: 25px;
    margin-bottom: 15px;
    margin-top: 5px;
}

/* Map Button */
.map-capsule {
    background-color: #e0f2fe;
    color: #0369a1 !important;
    border: 1px solid #bae6fd;
}

body.dark-mode .map-capsule {
    background-color: #0c4a6e;
    color: #7dd3fc !important;
    border-color: #075985;
}

/* Distance Badge */
.distance-capsule {
    background-color: #f1f5f9;
    color: #475569;
    border: 1px solid #e2e8f0;
}

body.dark-mode .distance-capsule {
    background-color: #334155;
    color: #e2e8f0;
    border-color: #475569;
}

.distance-capsule i {
    color: #f59e0b;
}

/* [File: public/css/chat-style.css] */

/* --- SCROLLING CAR ANIMATION & POSITION --- */
#timeline-car {
    position: absolute;
    left: 13px; /* Dotted line ke upar align */
    top: 60px;  /* Initial position */
    width: 34px;
    height: 34px;
    background: #ffffff;
    border: 2px solid #3498db;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #3498db;
    font-size: 15px;
    z-index: 100;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    
    /* [IMPORTANT] Transition HATA DI HAI taaki JS smooth drive kar sake */
    /* transition: top 0.15s ease-out; <--- YEH LINE DELETE KAR DEIN */
    will-change: top, transform; /* Performance Booster */
}

/* Dark Mode Car */
body.dark-mode #timeline-car {
    background: #0A192F;
    border-color: #bef264;
    color: #bef264;
    box-shadow: 0 0 15px rgba(190, 242, 100, 0.4);
}

/* ==========================================
   HOTEL BOOKING MODAL STYLING
   ========================================== */
#hotel-booking-modal .modal-content {
    max-width: 450px;
    padding: 25px;
    border-top: 5px solid var(--primary-color);
}

#hotel-booking-modal h3 {
    margin-bottom: 5px;
    font-size: 1.5rem;
}

#modal-hotel-name {
    font-size: 1.1rem;
    color: var(--text-primary);
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px dashed var(--border-color);
}

/* Form Grid for Dates and Numbers */
.booking-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 15px;
}

#hotel-booking-form label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 5px;
}

#hotel-booking-form input {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border-color);
    background-color: var(--bg-main);
    color: var(--text-primary);
    border-radius: 6px;
    font-size: 1rem;
    box-sizing: border-box;
    transition: border-color 0.3s;
}

#hotel-booking-form input:focus {
    border-color: var(--primary-color);
    outline: none;
}

/* Dark Mode Specifics */
body.dark-mode #hotel-booking-form input {
    background-color: #0f172a; /* Darker input bg */
    border-color: #334155;
}

#hotel-booking-form .book-btn {
    margin-top: 10px;
    width: 100%;
    padding: 12px;
    font-size: 1.1rem;
    background-color: #25D366; /* WhatsApp Green */
    color: white;
    border: none;
}
#hotel-booking-form .book-btn:hover {
    background-color: #1ebc57;
}

/* ==========================================
   1. HOTEL BOOKING CAPSULE (Small Button)
   ========================================== */
.book-capsule {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin-left: 10px;
    padding: 4px 12px;
    font-size: 0.8rem;
    background-color: #e8f5e9; /* Light Green */
    color: #25d366 !important; /* WhatsApp Green */
    border: 1px solid #25d366;
    border-radius: 50px;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
    font-weight: 700;
}

.book-capsule:hover {
    background-color: #25d366;
    color: white !important;
    transform: translateY(-2px);
    box-shadow: 0 2px 5px rgba(37, 211, 102, 0.3);
}

/* Dark Mode Hotel Button */
body.dark-mode .book-capsule {
    background-color: rgba(37, 211, 102, 0.1);
}

/* ==========================================
   2. FOOD SUGGESTION CARDS (Lunch/Dinner Group)
   ========================================== */
.food-box {
    background: #fff8e1; /* Light Yellow/Cream for Food */
    border-left: 4px solid #ffc107; /* Amber Line */
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 15px;
    margin-left: 5px; /* Align with timeline */
}

body.dark-mode .food-box {
    background: rgba(255, 193, 7, 0.1);
    color: #e2e8f0;
}

.food-title {
    font-weight: 800;
    color: #d35400; /* Orange Text */
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    text-transform: uppercase;
}

body.dark-mode .food-title {
    color: #ffca28; /* Lighter Yellow for Dark Mode */
}

.food-item {
    font-size: 0.9rem;
    margin-bottom: 5px;
    padding-left: 20px;
    position: relative;
    line-height: 1.5;
}

.food-item::before {
    content: '•';
    position: absolute;
    left: 5px;
    color: #ffc107;
    font-weight: bold;
}


/* --- public/css/chat-style.css --- */

/* Ensure Timeline Container is Relative for the Car */
.itinerary-timeline-container {
    position: relative; /* CRITICAL FIX FOR CAR */
    overflow: hidden; /* Keeps car inside */
}

/* FIX: Inline Hotel Booking Capsule */
.hotel-item .book-capsule {
    display: inline-flex; /* Makes it sit next to text */
    vertical-align: middle; /* Aligns vertically with text */
    margin-left: 10px;
    margin-top: 0; /* Remove top margin so it doesn't drop down */
    padding: 4px 12px;
    font-size: 0.75rem;
    background-color: #e8f5e9;
    color: #25d366 !important;
    border: 1px solid #25d366;
    border-radius: 50px;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
    font-weight: 700;
}

.hotel-item .book-capsule:hover {
    background-color: #25d366;
    color: white !important;
}

/* Food Card Styling (Organized look) */
.food-box.chronological {
    margin: 15px 0 15px 25px; /* Indent slightly to align with timeline activities */
    border-left: 3px solid #ffc107;
    background: #fffcf2;
    padding: 10px 15px;
    border-radius: 0 8px 8px 0;
    position: relative;
}

.food-box.chronological::before {
    /* Small connector dot on timeline */
    content: '';
    position: absolute;
    left: -29px; /* Adjust based on your timeline line position */
    top: 15px;
    width: 10px;
    height: 10px;
    background: #ffc107;
    border-radius: 50%;
    border: 2px solid var(--bg-main);
}

/* [FIX: FOOD CARD ALIGNMENT] */
.food-box {
    background: #fff8e1; 
    border-left: 4px solid #ffc107; 
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 15px;
    
    /* [CHANGE] Margin badhaya taaki car ke raste se hate */
    margin-left: 35px; /* 5px se 35px kiya */
    
    position: relative; /* For z-index */
    z-index: 1; /* Car ke peeche rahe */
}

/* Dark Mode Food Box */
body.dark-mode .food-box {
    background: rgba(255, 193, 7, 0.1);
    color: #e2e8f0;
    border-left: 4px solid #ffc107;
}

/* =========================================
   FINAL HEADING STYLE (Small & Centered)
   ========================================= */

.itinerary-main-title {
    max-width: 900px;
    width: 100%;
    margin: 20px auto; /* Top-Bottom margin thoda kam kiya */
    
    /* [UPDATED] Font Size & Alignment */
    font-size: 1.5rem;  /* Pehle 2.2rem tha, ab chota kar diya */
    text-align: center; /* Text ko beech (center) mein kiya */
    font-weight: 700;   /* Thoda bold */
    
    color: var(--heading-color);
    line-height: 1.5;   /* Lines ke beech thoda gap */
    padding: 0 15px;    /* Side mein thodi jagah */
    
    /* Text Wrapping (Taaki lambi heading tute nahi balki neeche aaye) */
    white-space: normal;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Mobile ke liye aur adjust karein */
@media (max-width: 768px) {
    .itinerary-main-title {
        font-size: 1.3rem; /* Mobile par aur chota */
        margin-top: 15px;
    }
}

/* =========================================
   UNIFIED DARK THEME FOR ALL CARDS
   ========================================= */

/* 1. Apply Dark Navy Background to ALL Cards in Dark Mode */
body.dark-mode .trip-summary-card,
body.dark-mode .destination-overview-card,
body.dark-mode .itinerary-display-card {
    background-color: #112240 !important; /* Exact same Dark Blue */
    border: 1px solid #233554 !important; /* Same Border */
    border-radius: 12px;
    box-shadow: 0 10px 30px -15px rgba(2,12,27,0.7);
    color: #e6f1ff; /* Light Text Color */
    margin-bottom: 30px; /* Spacing between cards */
}

/* 2. Headings inside these cards (e.g., "Destination Overview", "Day 1") */
body.dark-mode .destination-overview-card h3,
body.dark-mode .itinerary-display-card h3,
body.dark-mode .itinerary-day {
    color: #d2fa5c !important; /* Neon Green Title */
    font-weight: 700;
}

/* 3. Inner Boxes (Weather, Food, Hotels) - Thoda sa alag shade taaki visible rahein */
body.dark-mode .overview-item, 
body.dark-mode .hotel-option {
    background-color: #172a45 !important; /* Card se thoda sa light */
    border: 1px solid #303C55 !important;
    color: #8892b0 !important; /* Muted Text */
}

/* 4. Strong Text inside Inner Boxes */
body.dark-mode .overview-item strong,
body.dark-mode .hotel-option strong {
    color: #e6f1ff !important; /* Bright White for emphasis */
}

/* 5. Remove White Backgrounds if any remain */
body.dark-mode .itinerary-activity {
    background-color: transparent !important;
    border: none !important;
}

/* ==========================================
   HOTEL CARDS INSIDE CHAT BUBBLE
   ========================================== */

/* Chat Message Container Adjustment */
.chat-message.general-query-response {
    max-width: 850px; /* Thoda chauda karein taaki details fit hon */
    background-color: #1e293b; /* Dark Background for card */
    border: 1px solid #334155;
    color: #e2e8f0;
}

/* Book Button in Chat */
.chat-message .book-capsule {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    font-size: 0.85rem;
    background-color: rgba(37, 211, 102, 0.15); /* WhatsApp Green Tint */
    color: #25d366 !important; 
    border: 1px solid #25d366;
    border-radius: 50px;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
    font-weight: 700;
}

.chat-message .book-capsule:hover {
    background-color: #25d366;
    color: #000 !important;
    transform: translateY(-2px);
}

/* Category Headings */
.category-heading {
    font-size: 1.1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}