/* =============================
   CSS Custom Properties & Reset
============================= */
:root {
    --bg: #ffffff;
    --left-bg: #ffffff;
    --right-bg: #f8fafc;
    --border: #e2e8f0;
    --accent: #2563eb;
    --accent-dark: #1d4ed8;
    --accent-light: #3b82f6;
    --text-primary: #0f172a;
    --text-secondary: #64748b;
    --bubble-user: linear-gradient(135deg, #2563eb, #1d4ed8);
    --bubble-ai: #f1f5f9;
    --card-bg: #ffffff;
    --card-shadow: 0 4px 24px rgba(0,0,0,0.08);
    --day-accent: #1e3a8a;
    --day-accent-2: #3b82f6;
    --include-bg: #f0fdf4;
    --exclude-bg: #fff7ed;
    --green: #16a34a;
    --orange: #ea580c;
    font-size: 15px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    display: flex;
    height: 100vh;
    overflow: hidden;
    font-family: 'Inter', -apple-system, sans-serif;
    background: var(--bg);
}

.sidebar-tag {
    background: #f1f5f9;
    color: #64748b;
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    padding: 8px 20px;
    border-bottom: 1px solid var(--border);
    user-select: none;
}

/* =============================
   LEFT PANEL - Chat
============================= */
.left-panel {
    width: 420px;
    min-width: 380px;
    max-width: 460px;
    background: var(--left-bg);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    height: 100vh;
    flex-shrink: 0;
}

.sidebar-top-actions {
    padding: 0.75rem 1.25rem;
    border-bottom: 1px solid var(--border);
    display: flex;
    gap: 0.75rem;
    align-items: center;
    background: #f8fafc;
}

.sidebar-search-trigger {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.5rem 1rem;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    color: #64748b;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar-search-trigger:hover {
    background: white;
    border-color: var(--accent);
    color: var(--accent);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.08);
    transform: translateY(-1px);
}

.sidebar-search-trigger svg {
    color: var(--accent);
    opacity: 0.6;
}

.sidebar-search-trigger:hover svg {
    opacity: 1;
}

.btn-new-chat {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: white;
    color: var(--text-secondary);
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-new-chat:hover {
    color: var(--accent);
    border-color: var(--accent);
    background: #eff6ff;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.1);
}

.btn-new-chat svg {
    opacity: 0.7;
}

.btn-new-chat:hover svg {
    opacity: 1;
}

.chat-history {
    flex: 1;
    overflow-y: auto;
    padding: 1.25rem 1.25rem 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.chat-history::-webkit-scrollbar { width: 4px; }
.chat-history::-webkit-scrollbar-thumb { background: #e2e8f0; border-radius: 4px; }

/* Messages */
.message { display: flex; gap: 0.75rem; align-items: flex-start; }

.message-avatar {
    width: 32px;
    height: 32px;
    flex-shrink: 0;
    border-radius: 50%;
    background: rgba(59,130,246,0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}

.user-message { flex-direction: row-reverse; }

.user-message .message-avatar {
    background: rgba(59,130,246,0.3);
    color: #fff;
    font-size: 0.8rem;
    font-weight: 700;
}

.message-bubble {
    max-width: calc(100% - 50px);
    padding: 0.8rem 1rem;
    border-radius: 14px;
    font-size: 0.88rem;
    line-height: 1.55;
}

.ai-message .message-bubble {
    background: var(--bubble-ai);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    border-top-left-radius: 4px;
}

.user-message .message-bubble {
    background: var(--bubble-user);
    color: white;
    border-top-right-radius: 4px;
}

/* Quick suggestions */
.quick-suggestions {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.suggestion-chip {
    background: rgba(59,130,246,0.12);
    border: 1px solid rgba(59,130,246,0.25);
    color: var(--accent-light);
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    font-size: 0.8rem;
    cursor: pointer;
    text-align: left;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

.suggestion-chip:hover {
    background: rgba(59,130,246,0.25);
    border-color: var(--accent-light);
    color: white;
}

/* Chat Input */
.chat-input-area {
    padding: 1rem 1.25rem 1.25rem;
    border-top: 1px solid var(--border);
    background: rgba(255,255,255,0.02);
}

.input-wrapper {
    display: flex;
    align-items: flex-end;
    gap: 0.75rem;
    background: #f8fafc;
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 0.75rem 0.75rem 0.75rem 1rem;
    transition: all 0.2s;
}

.input-wrapper:focus-within { border-color: var(--accent); }

.input-wrapper textarea {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    font-size: 0.88rem;
    outline: none;
    resize: none;
    line-height: 1.5;
}

.input-wrapper textarea::placeholder { color: var(--text-secondary); }

#send-btn {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: var(--accent);
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.2s;
}

#send-btn:hover { background: var(--accent-dark); transform: scale(1.05); }
#send-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

.input-hint {
    font-size: 0.72rem;
    color: var(--text-secondary);
    margin-top: 0.5rem;
    text-align: center;
}

.input-hint kbd {
    background: rgba(255,255,255,0.08);
    padding: 1px 5px;
    border-radius: 4px;
    border: 1px solid var(--border);
}

/* Autocomplete / Elastic Search */
.autocomplete-items {
    position: absolute;
    bottom: calc(100% + 8px);
    left: 0;
    width: 250px;
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    z-index: 1000;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.autocomplete-item {
    padding: 10px 14px;
    font-size: 0.85rem;
    color: var(--text-primary);
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: background 0.15s;
    border-bottom: 1px solid #f1f5f9;
}

.autocomplete-item:last-child {
    border-bottom: none;
}

.autocomplete-item:hover, .autocomplete-item.active {
    background: rgba(59,130,246,0.25);
}

/* Activity suggestions that can be dragged into a day */
.autocomplete-item[draggable="true"] {
    cursor: grab;
}
.autocomplete-item[draggable="true"]:active {
    cursor: grabbing;
}

.autocomplete-item[draggable="true"]::after {
    content: 'Drag into a day →';
    display: block;
    margin-top: 4px;
    font-size: 0.7rem;
    color: rgba(191, 219, 254, 0.9);
}

/* Visual highlight when a day list is a drop target */
.activities-list.activities-drop-target {
    border-radius: 12px;
    background: #eff6ff;
    box-shadow: 0 0 0 1.5px #bfdbfe inset;
}

.autocomplete-item strong {
    color: var(--accent-light);
    font-weight: 700;
}

/* Day Selector Modal (Global Autocomplete Interceptor) */
.day-selector-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(4px);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

.day-selector-overlay.visible {
    opacity: 1;
    pointer-events: auto;
}

.day-selector-modal {
    background: var(--bg-panel);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 24px;
    width: 380px;
    max-width: 90vw;
    box-shadow: 0 12px 48px rgba(0,0,0,0.5);
    transform: scale(0.95) translateY(10px);
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.day-selector-overlay.visible .day-selector-modal {
    transform: scale(1) translateY(0);
}

.dsm-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.dsm-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.dsm-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 1.2rem;
}

.dsm-context {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 20px;
    line-height: 1.4;
}

.dsm-days-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    max-height: 300px;
    overflow-y: auto;
    padding-right: 4px;
}

.dsm-day-btn {
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border);
    color: var(--text-primary);
    padding: 12px;
    border-radius: 8px;
    cursor: pointer;
    text-align: center;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.dsm-day-btn:hover {
    background: rgba(59, 130, 246, 0.15);
    border-color: rgba(59, 130, 246, 0.4);
    transform: translateY(-1px);
}

.dsm-day-num {
    font-weight: 700;
    font-size: 1rem;
}

.dsm-day-title {
    font-size: 0.75rem;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* =============================
   RIGHT PANEL - Itinerary View
============================= */
.right-panel {
    flex: 1;
    height: 100vh;
    overflow-y: auto;
    background: var(--right-bg);
    position: relative;
}

.right-panel::-webkit-scrollbar { width: 6px; }
.right-panel::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 6px; }

.hidden { display: none !important; }

/* Empty State */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    text-align: center;
    padding: 2rem;
    color: #64748b;
}

.empty-icon { font-size: 4rem; margin-bottom: 1.5rem; }

.empty-state h2 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.75rem;
}

.empty-state p {
    font-size: 1rem;
    max-width: 450px;
    line-height: 1.6;
    margin-bottom: 2rem;
}

.empty-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    max-width: 400px;
}

.feature-item {
    background: white;
    padding: 0.75rem 1rem;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    font-size: 0.88rem;
    font-weight: 500;
    color: #334155;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Loading State */
.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    gap: 1rem;
}

.loading-animation {
    display: flex;
    gap: 8px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent);
    animation: bounce 1.2s ease-in-out infinite;
}

.dot:nth-child(2) { animation-delay: 0.2s; }
.dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes bounce {
    0%, 80%, 100% { transform: scale(0.6); opacity: 0.4; }
    40% { transform: scale(1); opacity: 1; }
}

.loading-text { font-size: 1.2rem; font-weight: 600; color: #1e293b; }
.loading-subtext { font-size: 0.88rem; color: #64748b; }

/* =============================
   DIVIDER ACTION BUTTON
   ============================= */
.divider-action-container {
    position: relative;
    width: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-divider-generate {
    position: absolute;
    left: 0.25rem; /* Perfectly centered on the narrow divider line */
    top: 0.75rem; /* Move right to the top border */
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 1.25rem;
    background: white;
    backdrop-filter: blur(12px);
    border: 2px solid var(--accent);
    border-radius: 100px;
    color: var(--accent);
    font-size: 0.82rem;
    font-weight: 800;
    cursor: pointer;
    white-space: nowrap;
    box-shadow: 0 10px 25px -5px rgba(37, 99, 235, 0.15);
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 200; /* Ensure on top of sticky nav */
    transform: translateY(0);
}

.btn-divider-generate:hover {
    background: var(--accent);
    color: white;
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 20px 35px -10px rgba(37, 99, 235, 0.3);
}

.btn-divider-generate .magic-icon {
    font-size: 1.2rem;
    animation: magic-spin 3s infinite linear;
}

@keyframes magic-spin {
    0% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(180deg) scale(1.2); }
    100% { transform: rotate(360deg) scale(1); }
}

.btn-divider-generate .btn-text {
    letter-spacing: -0.2px;
}

/* WhatsApp & PDF Buttons — fixed right side, stacked */
.btn-divider-whatsapp,
.btn-divider-pdf {
    position: fixed;
    right: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.1rem;
    background: white;
    border-radius: 100px;
    font-size: 0.82rem;
    font-weight: 800;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 2001;
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}

.btn-divider-whatsapp {
    top: 0.75rem;
    border: 2px solid #25D366;
    color: #128C7E;
}

.btn-divider-whatsapp:hover {
    background: #25D366;
    color: white;
    transform: translateY(-2px) scale(1.03);
    box-shadow: 0 8px 24px rgba(37, 211, 102, 0.35);
}

.btn-divider-pdf {
    top: 3.5rem;
    border: 2px solid #ef4444;
    color: #dc2626;
}

.btn-divider-pdf:hover {
    background: #ef4444;
    color: white;
    transform: translateY(-2px) scale(1.03);
    box-shadow: 0 8px 24px rgba(239, 68, 68, 0.35);
}

/* =============================
   ITINERARY CONTENT STYLES
   ============================= */
.itinerary-content {
    width: 100%;
    margin: 0;
    background: white;
    min-height: 100vh;
    box-shadow: none;
    border-left: 1px solid var(--border);
    border-right: 1px solid var(--border);
}

@media (max-width: 1400px) {
    .itinerary-content { width: 100%; }
}

@media (max-width: 1200px) {
    .itinerary-content { width: 100%; }
}

@media (max-width: 768px) {
    .itinerary-content { width: 100%; }
}

/* Hero Banner */
.itin-hero {
    background: linear-gradient(135deg, #1e3a8a 0%, #1d4ed8 50%, #2563eb 100%);
    padding: 3rem 2.5rem 2rem;
    color: white;
    position: relative;
    overflow: hidden;
}

.itin-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255,255,255,0.08) 0%, transparent 70%);
}

.itin-hero::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(255,255,255,0.05) 0%, transparent 70%);
}

.hero-label {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #93c5fd;
    margin-bottom: 0.5rem;
}

.itin-hero h1 {
    font-family: 'Playfair Display', serif;
    font-size: 2.4rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 0.75rem;
    position: relative;
    z-index: 1;
}

.hero-meta {
    display: flex;
    gap: 1.5rem;
    margin-top: 1.25rem;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

.hero-badge {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(255,255,255,0.15);
    padding: 0.4rem 0.85rem;
    border-radius: 20px;
    font-size: 0.82rem;
    font-weight: 500;
    backdrop-filter: blur(10px);
}

/* Package Highlights grid */
.highlights-section {
    background: white;
    padding: 2rem 2.5rem;
    border-bottom: 1px solid #e8f0fe;
}

.section-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.25rem;
}

.section-sub {
    font-size: 0.85rem;
    color: #64748b;
    margin-bottom: 1.25rem;
}

.highlights-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 0.75rem;
}

.highlight-chip {
    background: linear-gradient(135deg, #eff6ff, #dbeafe);
    border: 1px solid #bfdbfe;
    border-radius: 10px;
    padding: 0.7rem 0.9rem;
    font-size: 0.85rem;
    font-weight: 500;
    color: #1d4ed8;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Overview */
.overview-section {
    background: #fafbff;
    padding: 1.75rem 2.5rem;
    border-bottom: 1px solid #e8f0fe;
}

.overview-text {
    font-size: 0.95rem;
    line-height: 1.7;
    color: #475569;
    max-width: 700px;
}

/* Day Tabs Navigation */
.day-nav {
    background: white;
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 2px solid #e2e8f0;
    padding: 0 2rem;
    display: flex;
    gap: 0;
    overflow-x: auto;
}

.day-nav::-webkit-scrollbar { height: 3px; }
.day-nav::-webkit-scrollbar-thumb { background: #cbd5e1; }

.day-tab {
    padding: 0.9rem 1.25rem;
    font-size: 0.82rem;
    font-weight: 600;
    color: #64748b;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    white-space: nowrap;
    transition: all 0.2s;
    background: none;
    border-top: none;
    border-left: none;
    border-right: none;
    font-family: 'Inter', sans-serif;
    flex-shrink: 0;
}

.day-tab:hover { color: #1d4ed8; background: #f8faff; }

.day-tab.active {
    color: #1d4ed8;
    border-bottom-color: #1d4ed8;
    background: #eff6ff;
}

/* Day Cards */
.days-section { padding: 1.75rem 2.5rem; }

.day-card {
    background: white;
    border-radius: 16px;
    box-shadow: var(--card-shadow);
    margin-bottom: 1.5rem;
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
    border: 1px solid #e8f0fe;
}

.day-card:hover { transform: translateY(-2px); box-shadow: 0 8px 32px rgba(0,0,0,0.1); }

.day-card.collapsed {
    padding-bottom: 0px;
}

.day-card.collapsed .day-card-body {
    display: none;
}

.day-card-header {
    display: flex;
    gap: 1.25rem;
    padding: 1.5rem 1.75rem;
    background: linear-gradient(135deg, #f8faff, #eff6ff);
    border-bottom: 1px solid #e8f0fe;
    align-items: center; /* Changed from flex-start to center for better toggle alignment */
}

.day-card.collapsed .day-card-header {
    border-bottom: none;
}

.day-toggle-btn {
    background: #f1f5f9;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.day-toggle-btn:hover {
    background: #e2e8f0;
    color: #1d4ed8;
}

.day-card.collapsed .day-toggle-btn svg {
    transform: rotate(180deg);
}

.day-toggle-btn svg {
    transition: transform 0.3s ease;
}

.day-number-badge {
    background: var(--day-accent);
    color: white;
    border-radius: 12px;
    padding: 0.5rem 0.9rem;
    text-align: center;
    flex-shrink: 0;
}

.day-number-badge .day-label { font-size: 0.65rem; font-weight: 600; letter-spacing: 1px; text-transform: uppercase; opacity: 0.8; }
.day-number-badge .day-num { font-size: 1.8rem; font-weight: 800; line-height: 1; }

.day-title-wrap { flex: 1; }

.day-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.4rem;
    line-height: 1.3;
}

.day-meals {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-top: 0.5rem;
}

.meal-pill {
    background: #fef3c7;
    color: #92400e;
    padding: 0.2rem 0.6rem;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 600;
}

/* Activities List */
.activities-list {
    padding: 1rem 1.75rem 1.5rem;
}

.activities-label {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #94a3b8;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.activities-label::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e8f0fe;
}

.activity-item {
    display: flex;
    gap: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f1f5f9;
    align-items: flex-start;
    position: relative;
}

.activity-item:last-child { border-bottom: none; }

.activity-icon-wrap {
    width: 36px;
    height: 36px;
    background: #eff6ff;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    flex-shrink: 0;
    margin-top: 2px;
}

.activity-item.highlight .activity-icon-wrap {
    background: linear-gradient(135deg, #1d4ed8, #3b82f6);
}

.activity-body { flex: 1; }

/* Drag Handle */
.act-drag-handle {
    font-size: 1.15rem;
    color: #cbd5e1;
    cursor: grab;
    user-select: none;
    padding: 0 4px;
    display: flex;
    align-items: center;
    flex-shrink: 0;
    transition: color 0.15s;
    letter-spacing: -1px;
}

.act-drag-handle:active { cursor: grabbing; }
.activity-item:hover .act-drag-handle { color: #94a3b8; }

/* Dragging state */
.activity-item.dragging {
    opacity: 0.45;
    background: #f0f9ff;
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(59,130,246,0.18);
}

/* Activity Drop-target indicators */
.activity-item.drag-over-top {
    border-top: 2.5px solid #3b82f6;
    margin-top: -1px;
}
.activity-item.drag-over-bottom {
    border-bottom: 2.5px solid #3b82f6;
    margin-bottom: -1px;
}

/* Day Card Drag Handle */
.day-drag-handle {
    cursor: grab;
    width: 28px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #cbd5e1;
    font-size: 1.3rem;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    user-select: none;
    margin-right: -0.25rem;
    border-radius: 8px;
}

.day-drag-handle:hover { 
    color: var(--accent);
    background: rgba(59, 130, 246, 0.05);
}
.day-drag-handle:active { cursor: grabbing; transform: scale(0.95); }

/* Day Card Dragging state */
.day-card.dragging {
    opacity: 0.3 !important;
    transform: scale(0.98);
    filter: grayscale(0.5);
    border: 2px dashed var(--accent) !important;
    box-shadow: none !important;
}

/* Day Card Drop-target indicators */
.day-card.drag-over-top {
    border-top: 4px solid var(--accent) !important;
    box-shadow: 0 -12px 24px rgba(59, 130, 246, 0.1);
    transform: translateY(4px);
}
.day-card.drag-over-bottom {
    border-bottom: 4px solid var(--accent) !important;
    box-shadow: 0 12px 24px rgba(59, 130, 246, 0.1);
    transform: translateY(-4px);
}

/* Global Transition for smooth reordering */
.day-card {
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), 
                box-shadow 0.2s ease, 
                border 0.2s ease,
                opacity 0.2s ease;
}

/* Activity Item dragging refinement */
.activity-item.dragging {
    opacity: 0.4;
    background: rgba(239, 246, 255, 0.5);
    backdrop-filter: blur(4px);
    border-radius: 12px;
    border: 1.5px dashed var(--accent);
}

/* Clickable time pill */
.activity-time-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    color: var(--tcolor, #3b82f6);
    border: 1.5px solid var(--tcolor, #3b82f6);
    background: color-mix(in srgb, var(--tcolor, #3b82f6) 10%, white);
    border-radius: 20px;
    padding: 2px 9px 2px 6px;
    margin-bottom: 4px;
    cursor: pointer;
    user-select: none;
    transition: background 0.15s, transform 0.1s;
}

.activity-time-pill:hover {
    background: color-mix(in srgb, var(--tcolor, #3b82f6) 18%, white);
    transform: scale(1.04);
}

.activity-time-pill:active { transform: scale(0.97); }

.pill-clock { font-size: 0.75rem; line-height: 1; }

/* Flash when pill changes */
@keyframes pillFlash {
    0%   { transform: scale(1.15); }
    100% { transform: scale(1); }
}
.activity-time-pill.pill-changed {
    animation: pillFlash 0.35s ease;
}

.activity-title {
    font-size: 0.92rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.highlight-tag {
    background: linear-gradient(135deg, #1d4ed8, #3b82f6);
    color: white;
    font-size: 0.62rem;
    padding: 1px 6px;
    border-radius: 10px;
    font-weight: 600;
}

.activity-desc {
    font-size: 0.83rem;
    color: #64748b;
    line-height: 1.5;
}

/* Accommodation */
.accommodation-strip {
    background: linear-gradient(135deg, #f0fdf4, #dcfce7);
    border-top: 1px solid #bbf7d0;
    padding: 0.85rem 1.75rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.accommodation-icon {
    font-size: 1.1rem;
    background: white;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.accommodation-label {
    font-size: 0.72rem;
    color: #16a34a;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.accommodation-name {
    font-size: 0.88rem;
    color: #166534;
    font-weight: 600;
}

/* Inclusions & Exclusions */
.inc-exc-section {
    padding: 1.5rem 2.5rem;
    background: white;
    border-top: 1px solid #e8f0fe;
}

.inc-exc-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
    margin-top: 1rem;
}

.inc-box, .exc-box {
    border-radius: 14px;
    padding: 1.25rem;
}

.inc-box {
    background: var(--include-bg);
    border: 1px solid #bbf7d0;
}

.exc-box {
    background: var(--exclude-bg);
    border: 1px solid #fed7aa;
}

.box-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    margin-bottom: 0.75rem;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.inc-box .box-header {
    background: #16a34a;
    color: white;
}

.exc-box .box-header {
    background: #ea580c;
    color: white;
}

.box-item {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    padding: 0.4rem 0;
    font-size: 0.83rem;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.box-item:last-child { border-bottom: none; }

.inc-box .box-item { color: #166534; }
.exc-box .box-item { color: #9a3412; }

.box-item .dot-indicator {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    flex-shrink: 0;
    margin-top: 5px;
}

.inc-box .dot-indicator { background: #16a34a; }
.exc-box .dot-indicator { background: #ea580c; }

/* Pricing */
.pricing-section {
    background: linear-gradient(135deg, #1e3a8a, #1d4ed8);
    padding: 2rem 2.5rem;
    color: white;
}

.pricing-label {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #93c5fd;
    margin-bottom: 0.5rem;
}

.pricing-price {
    font-size: 2.5rem;
    font-weight: 800;
    font-family: 'Playfair Display', serif;
}

.pricing-note {
    font-size: 0.85rem;
    color: #bfdbfe;
    margin-top: 0.25rem;
}

/* Edit Tools Bar */
.edit-bar {
    background: var(--left-bg) !important;
    border-top: 1px solid var(--border);
}

/* Animation */
@keyframes slideIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.itinerary-content > * {
    animation: slideIn 0.5s ease forwards;
}

/* Error message */
.error-bubble {
    background: rgba(239,68,68,0.12);
    border: 1px solid rgba(239,68,68,0.25);
    color: #fca5a5;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    font-size: 0.85rem;
}

/* ── IMPORTANT NOTES ── */
.important-notes-section {
    padding: 2rem 2.5rem;
    margin-bottom: 2rem;
    animation: fadeUp .5s ease both;
    background: white;
    border-top: 1px solid #e8f0fe;
}

.important-notes-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.important-notes-title span {
    color: #16499a;
}

.important-notes-subtitle {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.important-notes-card {
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 2.5rem;
    box-shadow: var(--shadow-md);
    position: relative;
    overflow: hidden;
}

.important-notes-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem 3rem;
}

.important-note-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    font-size: 0.88rem;
    color: #475569;
    line-height: 1.5;
}

.important-note-item::before {
    content: "•";
    color: #94a3b8;
    font-size: 1.25rem;
    line-height: 0.8;
}

.expand-notes-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: transparent;
    border: none;
    color: #16499a;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    margin-top: 2rem;
    margin-left: auto;
    transition: opacity 0.2s;
}

.expand-notes-btn:hover {
    opacity: 0.8;
}

.expand-notes-btn svg {
    width: 0.75rem;
    height: 0.75rem;
    transition: transform 0.3s;
}

.expand-notes-btn.active svg {
    transform: rotate(180deg);
}

.hidden-note {
    display: none;
}

/* ── TERMS & CONDITIONS ── */
.terms-section {
    padding: 2rem 2.5rem;
    background: white;
    border-top: 1px solid #e8f0fe;
}

.terms-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 0.4rem;
}

.terms-title span {
    color: #16499a;
}

.terms-subtitle {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 1.75rem;
}

.terms-card {
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2rem 2.25rem;
    box-shadow: 0 2px 12px rgba(0,0,0,0.05);
}

.terms-group {
    margin-bottom: 1.5rem;
}

.terms-group:last-of-type {
    margin-bottom: 0;
}

.terms-group-title {
    font-size: 0.92rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.6rem;
}

.terms-item {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    font-size: 0.83rem;
    color: #475569;
    line-height: 1.55;
    padding: 0.2rem 0;
}

.terms-item::before {
    content: "•";
    color: #94a3b8;
    font-size: 1.1rem;
    line-height: 0.85;
    flex-shrink: 0;
}

.terms-footer-note {
    margin-top: 1.75rem;
    padding-top: 1.25rem;
    border-top: 1px solid #e8f0fe;
    font-size: 0.8rem;
    color: #94a3b8;
    text-align: center;
    line-height: 1.6;
}

.terms-expand-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: transparent;
    border: 1.5px solid #cbd5e1;
    color: #16499a;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    margin: 1.5rem auto 0;
    padding: 0.5rem 1.5rem;
    border-radius: 20px;
    transition: all 0.2s;
}

.terms-expand-btn:hover {
    border-color: #16499a;
    background: #eff6ff;
}

.terms-expand-btn svg {
    width: 0.75rem;
    height: 0.75rem;
    transition: transform 0.3s;
}

.terms-expand-btn.active svg {
    transform: rotate(180deg);
}

.terms-hidden-group {
    display: none;
}

/* ── CANCELLATION POLICY ── */
.cancel-policy-section {
    padding: 2rem 2.5rem;
    background: white;
    border-top: 1px solid #e8f0fe;
}

.cancel-policy-title {
    font-size: 2rem;
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 0.4rem;
}

.cancel-policy-title span {
    color: #ef4444;
}

.cancel-policy-subtitle {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 1.75rem;
}

.cancel-policy-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 2px 12px rgba(0,0,0,0.05);
}

.cancel-policy-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.cancel-col-title {
    font-size: 1rem;
    font-weight: 800;
    color: #ef4444;
    margin-bottom: 1rem;
}

.cancel-tier {
    background: #fff;
    border: 1px solid #e8f0fe;
    border-radius: 10px;
    padding: 0.85rem 1rem;
    margin-bottom: 0.75rem;
}

.cancel-tier-label {
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #ef4444;
    margin-bottom: 0.35rem;
}

.cancel-tier-desc {
    font-size: 0.85rem;
    color: #1e293b;
    font-weight: 600;
    line-height: 1.45;
}

.cancel-notice {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-top: 1.5rem;
    background: linear-gradient(135deg, #fff1f2, #ffe4e6);
    border: 1px solid #fecdd3;
    border-radius: 10px;
    padding: 1rem 1.25rem;
}

.cancel-notice-icon {
    font-size: 1.25rem;
    flex-shrink: 0;
    margin-top: 1px;
}

.cancel-notice-text {
    font-size: 0.83rem;
    color: #9f1239;
    font-weight: 600;
    line-height: 1.55;
}

/* =============================
   ENHANCED ACTIVITIES SECTION
============================= */
.enhanced-acts-section {
    padding: 2rem 2.5rem;
    background: #f8faff;
    border-top: 1px solid #e8f0fe;
}

.enhanced-acts-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

/* City filter pills */
.city-filter {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    align-items: center;
}

.city-pill {
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    border: 1.5px solid #cbd5e1;
    background: white;
    color: #475569;
    transition: all 0.18s;
    font-family: 'Inter', sans-serif;
}

.city-pill:hover {
    border-color: #3b82f6;
    color: #1d4ed8;
    background: #eff6ff;
}

.city-pill.active {
    background: #1d4ed8;
    border-color: #1d4ed8;
    color: white;
}

/* Activities grid — responsive 3 columns */
.acts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.25rem;
}

/* Individual Activity Card */
.act-card {
    background: white;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid #e2eaf8;
    box-shadow: 0 3px 12px rgba(0,0,0,0.06);
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
}

.act-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 28px rgba(0,0,0,0.1);
}

/* Top color strip with emoji */
.act-card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.6rem 0.85rem;
    background: linear-gradient(135deg, #1e3a8a, #2563eb);
}

.act-city-badge {
    color: white;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    background: rgba(255,255,255,0.2);
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
}

.act-photo-icon {
    font-size: 1.5rem;
    line-height: 1;
}

/* Card body */
.act-card-body {
    padding: 1rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.act-name {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.3;
}

.act-location {
    font-size: 0.78rem;
    color: #64748b;
    font-weight: 500;
}

.act-desc {
    font-size: 0.8rem;
    color: #475569;
    line-height: 1.5;
    flex: 1;
}

/* Theme tags */
.act-theme-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-top: 0.25rem;
}

.act-theme-tag {
    background: #eff6ff;
    color: #2563eb;
    border: 1px solid #bfdbfe;
    padding: 0.15rem 0.55rem;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 500;
}

/* Meta grid — 2 columns */
.act-meta-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.4rem 0.75rem;
    margin-top: 0.5rem;
    padding-top: 0.6rem;
    border-top: 1px solid #f1f5f9;
}

.act-meta-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 0.75rem;
    color: #334155;
}

.act-meta-label {
    font-size: 0.68rem;
    color: #94a3b8;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* Footer: price + crowd */
.act-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.7rem 1rem;
    background: linear-gradient(135deg, #f8faff, #eff6ff);
    border-top: 1px solid #e8f0fe;
    margin: 0 -1rem -1rem;
}

.act-price {
    font-size: 0.8rem;
    font-weight: 700;
    color: #1d4ed8;
}

.act-crowd {
    font-size: 0.75rem;
    color: #64748b;
    font-weight: 500;
}

/* =============================
   TOUR COST SECTION
============================= */
.tour-cost-section {
    background: white;
    padding: 2rem 2.5rem;
    border-top: 1px solid #e8f0fe;
}

.tc-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.tc-title {
    font-size: 1.75rem;
    font-weight: 800;
    color: #1e3a8a;
    letter-spacing: -0.5px;
}

/* Hotel category switcher */
.hcat-switcher {
    display: flex;
    gap: 0;
    border: 1.5px solid #cbd5e1;
    border-radius: 8px;
    overflow: hidden;
}

.hcat-tab {
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: #475569;
    background: white;
    border: none;
    border-right: 1.5px solid #cbd5e1;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: all 0.18s;
}

.hcat-tab:last-child { border-right: none; }
.hcat-tab:hover { background: #eff6ff; color: #1d4ed8; }
.hcat-tab.active { background: #1d4ed8; color: white; }

/* Table */
.tc-table-wrap {
    border-radius: 12px;
    overflow: hidden;
    border: 1.5px solid #e2e8f0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}

.tc-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.tc-th {
    background: #f8faff;
    color: #1e3a8a;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 0.85rem 1.25rem;
    border-bottom: 2px solid #e2e8f0;
    text-align: left;
}

.tc-th-nos, .tc-th-price { text-align: center; }

/* Body rows */
.tc-row td {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
}

.tc-pax-type {
    font-weight: 600;
    color: #1e293b;
    font-size: 0.92rem;
}

.tc-pax-note {
    font-size: 0.72rem;
    color: #94a3b8;
    margin-top: 2px;
}

/* NOS Stepper */
.tc-stepper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.tc-stepper button {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1.5px solid #cbd5e1;
    background: white;
    color: #475569;
    font-size: 1.1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
    line-height: 1;
    font-family: 'Inter', sans-serif;
}

.tc-stepper button:hover {
    background: #1d4ed8;
    border-color: #1d4ed8;
    color: white;
}

.tc-stepper span {
    min-width: 28px;
    text-align: center;
    font-size: 1rem;
    font-weight: 700;
    color: #1e293b;
}

/* Amount cell */
.tc-amt {
    text-align: center;
    vertical-align: middle;
}

.tc-per {
    display: block;
    font-size: 0.72rem;
    color: #64748b;
    margin-bottom: 2px;
}

/* TOTAL row */
.tc-total-row td {
    background: linear-gradient(135deg, #1e40af 0%, #1d4ed8 100%);
    color: white;
    padding: 1.1rem 1.25rem;
    font-size: 0.82rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    border-bottom: none;
}

.tc-total-row td:last-child { text-align: center; }

/* Tax rows */
.tc-tax-row {
    transition: background 0.2s ease;
}

.tc-tax-row:hover {
    background: #f8fafc;
}

.tc-tax-row td {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #f1f5f9;
    color: #475569;
    font-size: 0.9rem;
    font-weight: 500;
}

.tc-tax-row td:last-child { 
    text-align: center; 
    font-weight: 700; 
    color: #1e293b;
}

/* GRAND TOTAL row */
.tc-grand-row td {
    background: linear-gradient(135deg, #059669 0%, #10b981 100%);
    color: white;
    padding: 1.25rem 1.25rem;
    font-size: 0.95rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: none;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.1);
}

.tc-grand-row td:first-child {
    border-bottom-left-radius: 12px;
}

.tc-grand-row td:last-child {
    text-align: center;
    font-size: 1.35rem;
    font-family: 'Playfair Display', serif;
    border-bottom-right-radius: 12px;
}

/* Note below table */
.tc-note {
    font-size: 0.75rem;
    color: #94a3b8;
    text-align: right;
    margin-top: 0.75rem;
    font-style: italic;
}

/* =============================
   INLINE EDIT / ADD / DELETE CONTROLS
   ============================= */

/* Section-level header row with pencil + add buttons */
.section-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.section-actions {
    display: flex;
    gap: 0.4rem;
    align-items: center;
    opacity: 0;
    transition: opacity 0.2s;
}

.highlights-section:hover .section-actions,
.overview-section:hover .section-actions,
.inc-exc-section:hover .section-actions,
.enhanced-acts-section:hover .section-actions,
.pricing-section:hover .section-actions {
    opacity: 1;
}

/* Shared icon button base */
.btn-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.15s;
    background: transparent;
    font-family: 'Inter', sans-serif;
    flex-shrink: 0;
}

.btn-icon-add {
    background: #eff6ff;
    color: #1d4ed8;
    border: 1.5px solid #bfdbfe;
}
.btn-icon-add:hover { background: #1d4ed8; color: white; }

.btn-icon-edit {
    background: #f8faff;
    color: #475569;
    border: 1.5px solid #e2e8f0;
}
.btn-icon-edit:hover { background: #64748b; color: white; }

/* Mother Package Button in Editor */
.btn-icon-mother {
    background: #f0f9ff;
    color: #0369a1;
    border: 1.5px solid #bae6fd;
}
.btn-icon-mother:hover { background: #0369a1; color: white; }

.btn-icon-delete {
    background: #fff5f5;
    color: #ef4444;
    border: 1.5px solid #fecaca;
}
.btn-icon-delete:hover { background: #ef4444; color: white; }

/* Inline text styled as button */
.btn-add-text {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.3rem 0.75rem;
    border-radius: 8px;
    border: 1.5px dashed #bfdbfe;
    background: transparent;
    color: #1d4ed8;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    font-family: 'Inter', sans-serif;
    margin-top: 0.5rem;
    width: 100%;
}
.btn-add-text:hover { background: #eff6ff; border-style: solid; }

/* Highlight chip with delete */
.highlight-chip {
    position: relative;
}
.highlight-chip .chip-del {
    position: absolute;
    top: -7px;
    right: -7px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #ef4444;
    color: white;
    border: none;
    font-size: 0.65rem;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    line-height: 1;
    font-weight: 700;
    box-shadow: 0 1px 4px rgba(0,0,0,0.18);
}
.highlight-chip:hover .chip-del { display: flex; }

/* Box item (inclusion/exclusion) row */
.box-item {
    position: relative;
}
.box-item .item-del {
    margin-left: auto;
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: #cbd5e1;
    font-size: 0.75rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.15s, background 0.15s, color 0.15s;
}
.box-item:hover .item-del { opacity: 1; }
.inc-box .box-item:hover .item-del:hover { background: #ef4444; color: white; }
.exc-box .box-item:hover .item-del:hover { background: #ef4444; color: white; }

/* Add inclusion/exclusion row */
.inc-add-row, .exc-add-row {
    display: flex;
    gap: 0.4rem;
    margin-top: 0.4rem;
    align-items: center;
}
.inc-add-row input, .exc-add-row input {
    flex: 1;
    border: 1.5px solid #bbf7d0;
    border-radius: 8px;
    padding: 0.4rem 0.65rem;
    font-size: 0.82rem;
    outline: none;
    font-family: 'Inter', sans-serif;
    background: white;
    color: #166534;
}
.exc-add-row input {
    border-color: #fed7aa;
    color: #9a3412;
}
.inc-add-row input:focus { border-color: #16a34a; }
.exc-add-row input:focus { border-color: #ea580c; }

/* Activity row actions */
.act-row-actions {
    display: flex;
    gap: 0.25rem;
    flex-shrink: 0;
    opacity: 0;
    transition: opacity 0.15s;
}
.activity-item:hover .act-row-actions { opacity: 1; }

/* Add activity button */
.add-activity-btn {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    width: 100%;
    padding: 0.5rem 0.75rem;
    margin-top: 0.75rem;
    border: 1.5px dashed #bfdbfe;
    background: transparent;
    border-radius: 10px;
    color: #1d4ed8;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    font-family: 'Inter', sans-serif;
}
.add-activity-btn:hover { background: #eff6ff; border-style: solid; }

/* ── Activity Suggestion Panel ───────────────────── */
.act-suggest-panel {
    background: #fff;
    border: 1.5px solid #e2e8f0;
    border-radius: 14px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.12);
    padding: 0;
    margin: 0.75rem 0;
    overflow: hidden;
    font-family: 'Inter', sans-serif;
}
.act-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    background: linear-gradient(135deg, #1d4ed8, #3b82f6);
    color: #fff;
}
.act-panel-title { font-weight: 700; font-size: 0.9rem; }
.act-panel-close {
    background: rgba(255,255,255,0.2);
    border: none;
    color: #fff;
    border-radius: 6px;
    width: 26px;
    height: 26px;
    cursor: pointer;
    font-size: 0.85rem;
    line-height: 1;
    transition: background 0.15s;
}
.act-panel-close:hover { background: rgba(255,255,255,0.35); }
.act-panel-search-row {
    padding: 0.6rem 1rem;
    border-bottom: 1px solid #f1f5f9;
}
.act-panel-input {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.88rem;
    font-family: 'Inter', sans-serif;
    outline: none;
    transition: all 0.2s;
    box-sizing: border-box;
    background: white;
    color: #0f172a;
}
.act-panel-input:focus { 
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}
.act-panel-suggestions {
    max-height: 220px;
    overflow-y: auto;
    padding: 0.4rem 0;
}
.act-sugg-loading, .act-sugg-empty {
    padding: 0.8rem 1rem;
    color: #94a3b8;
    font-size: 0.82rem;
    text-align: center;
}
.act-sugg-row {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.5rem 1rem;
    cursor: pointer;
    transition: background 0.12s;
    border-radius: 0;
}
.act-sugg-row:hover { background: #eff6ff; }
.act-sugg-row.selected { background: #dbeafe; }
.act-sugg-icon { font-size: 1.1rem; flex-shrink: 0; }
.act-sugg-info { flex: 1; min-width: 0; }
.act-sugg-title { font-size: 0.84rem; font-weight: 500; color: #1e293b; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.act-sugg-day { font-size: 0.72rem; color: #64748b; background: #f1f5f9; border-radius: 4px; padding: 1px 6px; margin-top: 2px; display: inline-block; }
.act-panel-custom {
    padding: 0.75rem 1rem;
    border-top: 1px solid #f1f5f9;
    background: #fafafa;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}
.act-panel-divider { font-size: 0.75rem; color: #94a3b8; text-align: center; }
.act-custom-title, .act-custom-desc, .act-custom-time {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.88rem;
    font-family: 'Inter', sans-serif;
    background: white;
    color: #0f172a;
    outline: none;
    box-sizing: border-box;
    transition: all 0.2s;
}
.act-custom-title:focus, .act-custom-desc:focus, .act-custom-time:focus { 
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}
.act-custom-desc { resize: vertical; min-height: 52px; }
.act-panel-btns { display: flex; gap: 0.5rem; justify-content: flex-end; margin-top: 0.25rem; }
.act-cancel-btn {
    padding: 0.4rem 0.8rem;
    border: 1.5px solid #e2e8f0;
    background: #fff;
    border-radius: 8px;
    font-size: 0.82rem;
    cursor: pointer;
    color: #64748b;
    font-family: 'Inter', sans-serif;
}
.act-save-btn {
    padding: 0.4rem 1rem;
    background: #1d4ed8;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: background 0.15s;
}
.act-save-btn:hover { background: #1e40af; }

/* ── Inline Edit Activity Panel ─────────────────── */
.act-edit-panel {
    background: #fff;
    border: 1.5px solid #bfdbfe;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.10);
    padding: 0;
    margin: 0.5rem 0 0.75rem;
    overflow: hidden;
    font-family: 'Inter', sans-serif;
}
.act-edit-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.6rem 1rem;
    background: linear-gradient(135deg, #1d4ed8, #3b82f6);
    color: #fff;
    font-weight: 700;
    font-size: 0.88rem;
}
.act-edit-close {
    background: rgba(255,255,255,0.2);
    border: none;
    color: #fff;
    border-radius: 6px;
    width: 24px;
    height: 24px;
    cursor: pointer;
    font-size: 0.82rem;
    line-height: 1;
}
.act-edit-close:hover { background: rgba(255,255,255,0.35); }
.act-edit-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    color: #64748b;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin: 0.6rem 1rem 0.2rem;
}
.act-edit-title,
.act-edit-desc,
.act-edit-time {
    display: block;
    width: calc(100% - 2rem);
    margin: 0 1rem;
    padding: 0.42rem 0.7rem;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.85rem;
    font-family: 'Inter', sans-serif;
    outline: none;
    box-sizing: border-box;
    transition: border 0.15s;
}
.act-edit-title:focus,
.act-edit-desc:focus,
.act-edit-time:focus { border-color: #3b82f6; }
.act-edit-desc { resize: vertical; min-height: 64px; }
.act-edit-btns {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
    padding: 0.75rem 1rem;
}
.act-edit-cancel {
    padding: 0.4rem 0.8rem;
    border: 1.5px solid #e2e8f0;
    background: #fff;
    border-radius: 8px;
    font-size: 0.82rem;
    cursor: pointer;
    color: #64748b;
    font-family: 'Inter', sans-serif;
}
.act-edit-save {
    padding: 0.4rem 1rem;
    background: #1d4ed8;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: background 0.15s;
}
.act-edit-save:hover { background: #1e40af; }


/* ==========================================================================
   HOTELS SECTION ("Where You'll Stay")
   ========================================================================== */

.hotels-section {
    padding: 1.5rem;
    margin-bottom: 2rem;
    background: transparent;
    border: none;
    box-shadow: none;
}
.hotels-header-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}
.hotels-title {
    font-size: 1.8rem;
    font-weight: 800;
    color: #1e293b;
    margin: 0 0 0.25rem 0;
    letter-spacing: -0.02em;
}
.hotels-subtitle {
    font-size: 0.95rem;
    color: #64748b;
    margin: 0;
}
.hotel-tabs {
    display: inline-flex;
    background: #fff;
    border-radius: 30px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    padding: 4px;
    border: 1px solid #e2e8f0;
}
.hotel-tab-btn {
    background: transparent;
    border: none;
    padding: 0.5rem 1.25rem;
    border-radius: 26px;
    font-size: 0.75rem;
    font-weight: 700;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}
.hotel-tab-btn.active {
    background: #0ea5e9;
    color: #fff;
    box-shadow: 0 2px 8px rgba(14,165,233,0.3);
}

.hotel-cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

/* Visual highlight when hotel section is a drop target */
.hotels-section.hotels-drop-target {
    border-radius: 18px;
    box-shadow: 0 0 0 2px #bfdbfe inset;
    background: #eff6ff;
}

/* Hotel search row */
.hotel-search-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 0 1rem;
}
.hotel-search-left {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.hotel-search-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #1e293b;
}
.hotel-search-sub {
    font-size: 0.75rem;
    color: #94a3b8;
}
.hotel-search-right {
    display: flex;
    gap: 0.4rem;
    align-items: center;
}
.hotel-search-input {
    min-width: 220px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.4rem 0.75rem;
    font-size: 0.85rem;
    outline: none;
    font-family: 'Inter', sans-serif;
}
.hotel-search-input:focus {
    border-color: #2563eb;
}
.hotel-search-btn {
    padding: 0.4rem 0.9rem;
    border-radius: 8px;
    border: none;
    background: #2563eb;
    color: #fff;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: background 0.15s;
}
.hotel-search-btn:hover {
    background: #1d4ed8;
}
.hotel-extra-container {
    margin-top: 0.75rem;
}
.hotel-extra-title-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}
.hotel-extra-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: #1e293b;
}
.hotel-search-count {
    font-size: 0.75rem;
    color: #64748b;
    font-weight: 600;
}
.hotel-search-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 0.75rem;
}
.hotel-search-item {
    background: #fff;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.hotel-search-img {
    width: 100%;
    height: 100px;
    object-fit: cover;
}
.hotel-search-tags {
    display: flex;
    gap: 4px;
    padding: 4px 6px 0;
    flex-wrap: wrap;
}
.hotel-search-tag {
    font-size: 0.6rem;
    padding: 1px 5px;
    border-radius: 4px;
    font-weight: 600;
    text-transform: uppercase;
}
.hotel-search-tag.region {
    background: #e0f2fe;
    color: #0369a1;
}
.hotel-search-tag.type {
    background: #fef3c7;
    color: #92400e;
}
.hotel-search-name {
    font-size: 0.78rem;
    color: #1e293b;
    font-weight: 600;
    padding: 4px 6px 0;
}
.hotel-search-meta {
    font-size: 0.7rem;
    color: #64748b;
    padding: 0 6px 4px;
}
.hotel-add-btn {
    margin: 4px 6px 6px;
    background: #2563eb;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 4px 0;
    font-size: 0.73rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    text-align: center;
}
.hotel-add-btn:hover {
    background: #1d4ed8;
}
.hotel-add-btn.added {
    background: #16a34a;
    cursor: default;
}
.hotel-search-status {
    font-size: 0.82rem;
    color: #64748b;
    padding: 0.5rem 0.25rem;
}
.hotel-search-empty {
    color: #9ca3af;
}
.hotel-search-error {
    color: #b91c1c;
}
.hotel-card {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    border: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s, box-shadow 0.2s;
}
.hotel-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.1);
}

.hc-image-wrap {
    position: relative;
    height: 180px;
    width: 100%;
    background: #f1f5f9;
}
.hc-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.hc-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: rgba(15,23,42,0.7);
    backdrop-filter: blur(4px);
    color: #fff;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}
.hc-stars {
    position: absolute;
    top: 12px;
    right: 12px;
    background: #fff;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.75rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.hc-content {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}
.hc-name {
    margin: 0 0 0.5rem 0;
    font-size: 1.15rem;
    font-weight: 700;
    color: #0f172a;
    line-height: 1.3;
}
.hc-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
    font-size: 0.8rem;
    font-weight: 600;
}
.hc-room-type { color: #334155; }
.hc-location { color: #0ea5e9; }
.hc-desc {
    font-size: 0.85rem;
    color: #64748b;
    line-height: 1.5;
    margin: 0 0 1.25rem 0;
    flex: 1;
}

.hc-map-btn {
    width: 100%;
    padding: 0.6rem;
    background: #fff;
    border: 1.5px solid #0ea5e9;
    color: #0ea5e9;
    border-radius: 8px;
    font-weight: 700;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: all 0.2s;
    text-transform: uppercase;
}
.hc-map-btn:hover {
    background: #f0f9ff;
    box-shadow: 0 2px 8px rgba(14,165,233,0.15);
}
.hc-map-btn.disabled,
.hc-map-btn:disabled {
    border-color: #e2e8f0;
    color: #cbd5e1;
    cursor: not-allowed;
    background: #f8fafc;
    box-shadow: none;
}



/* Day title edit */
.day-title-editable {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.day-title-editable .btn-icon-edit {
    opacity: 0;
    transition: opacity 0.15s;
}
.day-title-editable .btn-icon-mother {
    opacity: 1 !important;
    display: inline-flex !important;
}
.day-card-header:hover .day-title-editable .btn-icon-edit { opacity: 1; }

/* Recommended Activity card delete button */
.act-card {
    position: relative;
}
.act-card-del {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: rgba(239,68,68,0.85);
    color: white;
    border: none;
    font-size: 0.8rem;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    line-height: 1;
    backdrop-filter: blur(4px);
    z-index: 2;
    transition: background 0.15s;
}
.act-card:hover .act-card-del { display: flex; }
.act-card-del:hover { background: #dc2626; }

/* Inline Editor Modal (floating pop-over) */
.inline-editor-overlay {
    position: fixed;
    inset: 0;
    z-index: 999;
    background: transparent;
}
.inline-editor {
    position: fixed;
    z-index: 1000;
    background: white;
    border: 1.5px solid #bfdbfe;
    border-radius: 14px;
    padding: 1rem;
    box-shadow: 0 8px 32px rgba(0,0,0,0.14);
    width: 320px;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    animation: editorPop 0.18s ease;
}
@keyframes editorPop {
    from { opacity: 0; transform: scale(0.95) translateY(-4px); }
    to   { opacity: 1; transform: scale(1) translateY(0); }
}
.inline-editor label {
    font-size: 0.75rem;
    font-weight: 700;
    color: #64748b;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}
.inline-editor input,
.inline-editor textarea,
.inline-editor select {
    width: 100%;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.6rem 0.8rem;
    font-family: 'Inter', sans-serif;
    font-size: 0.92rem;
    background: white;
    color: #0f172a;
    outline: none;
    resize: vertical;
    transition: all 0.2s;
}
.inline-editor input:focus,
.inline-editor textarea:focus,
.inline-editor select:focus { 
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}
.inline-editor textarea { min-height: 70px; }
.inline-editor-actions {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
}
.inline-editor-actions button {
    padding: 0.4rem 1rem;
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: all 0.15s;
    border: none;
}
.btn-editor-save {
    background: #1d4ed8;
    color: white;
}
.btn-editor-save:hover { background: #1e40af; }
.btn-editor-cancel {
    background: #f1f5f9;
    color: #475569;
}
.btn-editor-cancel:hover { background: #e2e8f0; }

/* Pricing note editable */
.pricing-note-wrap {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.25rem;
}
.pricing-note-wrap .btn-icon-edit {
    background: rgba(255,255,255,0.15);
    border-color: rgba(255,255,255,0.25);
    color: rgba(255,255,255,0.8);
    opacity: 0;
    transition: opacity 0.15s;
}
.pricing-section:hover .pricing-note-wrap .btn-icon-edit { opacity: 1; }
.pricing-note-wrap .btn-icon-edit:hover { background: rgba(255,255,255,0.3); color: white; }


/* =============================
   PHOTO GALLERY
============================= */
.photo-gallery-section {
    padding: 1.75rem 2.5rem 2rem;
    background: #fafbff;
    border-top: 1px solid #e8f0fe;
}
.photo-gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
    margin-top: 1rem;
}
.gallery-tile {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    cursor: zoom-in;
    aspect-ratio: 4 / 3;
    background: #e2e8f0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    transition: transform 0.22s, box-shadow 0.22s;
}
.gallery-tile:hover {
    transform: scale(1.03);
    box-shadow: 0 8px 28px rgba(0,0,0,0.18);
    z-index: 2;
}
/* .gallery-tile-wide { grid-column: span 2; aspect-ratio: 16/9; } */
.gallery-tile img {
    width: 100%; height: 100%;
    object-fit: cover; display: block;
    transition: transform 0.35s;
}
.gallery-tile:hover img { transform: scale(1.06); }
.gallery-caption {
    position: absolute; bottom: 0; left: 0; right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.65), transparent);
    color: white; font-size: 0.78rem; font-weight: 500;
    padding: 1.5rem 0.85rem 0.65rem; pointer-events: none;
}

/* =============================
   LIGHTBOX
============================= */
#gallery-lightbox { display: none; position: fixed; inset: 0; z-index: 9999; align-items: center; justify-content: center; }
#gallery-lightbox.lb-open { display: flex; }
.lb-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,0.88); backdrop-filter: blur(6px); }
.lb-box { position: relative; z-index: 1; display: flex; align-items: center; gap: 1rem; max-width: 90vw; max-height: 90vh; flex-direction: column; }
.lb-img { max-width: 85vw; max-height: 78vh; border-radius: 14px; box-shadow: 0 20px 60px rgba(0,0,0,0.6); object-fit: contain; display: block; }
.lb-close { position: fixed; top: 1.25rem; right: 1.5rem; background: rgba(255,255,255,0.12); border: 1px solid rgba(255,255,255,0.2); color: white; width: 40px; height: 40px; border-radius: 50%; font-size: 1.1rem; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: background 0.2s; z-index: 2; }
.lb-close:hover { background: rgba(255,255,255,0.25); }
.lb-prev, .lb-next { position: fixed; top: 50%; transform: translateY(-50%); background: rgba(255,255,255,0.12); border: 1px solid rgba(255,255,255,0.2); color: white; width: 48px; height: 48px; border-radius: 50%; font-size: 1.6rem; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: background 0.2s; z-index: 2; }
.lb-prev { left: 1.25rem; }
.lb-next { right: 1.25rem; }
.lb-prev:hover, .lb-next:hover { background: rgba(255,255,255,0.28); }
.lb-caption { color: rgba(255,255,255,0.85); font-size: 0.88rem; text-align: center; font-weight: 500; margin-top: 0.25rem; max-width: 80vw; }
.lb-counter { color: rgba(255,255,255,0.45); font-size: 0.75rem; text-align: center; }

/* Gallery inside day card (above Overnight Stay) */
.day-card .photo-gallery-section {
    padding: 0.75rem 1.75rem 0;
    background: transparent;
    border-top: 1px solid #f1f5f9;
    border-bottom: none;
}
.day-card .section-title { font-size: 0.72rem; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase; color: #94a3b8; margin-bottom: 0; }
.day-card .section-sub { display: none; }
.day-card .photo-gallery-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
    margin-top: 0.65rem;
    margin-bottom: 0.85rem;
}
.day-card .gallery-tile { aspect-ratio: 4/3; border-radius: 9px; }
/* .day-card .gallery-tile-wide { grid-column: span 2; aspect-ratio: 16/7; } */

/* =============================
   HERO BANNER IMAGES + OVERLAY
============================= */
.itin-hero {
    position: relative;
    overflow: hidden;
    min-height: 280px;
}

/* Sliding background images */
.hero-slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1.2s ease;
    z-index: 0;
}
.hero-slide.active { opacity: 1; }

/* Gradient overlay so text is always readable */
.hero-overlay {
    position: relative;
    z-index: 1;
    padding: 3rem 2.5rem 2rem;
    background: linear-gradient(
        135deg,
        rgba(15,30,80,0.82) 0%,
        rgba(20,60,180,0.65) 60%,
        rgba(37,99,235,0.45) 100%
    );
    min-height: 280px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

/* When no banner image: keep original blue gradient via pseudo-elements */
.itin-hero:not(:has(.hero-slide)) {
    background: linear-gradient(135deg, #1e3a8a 0%, #1d4ed8 50%, #2563eb 100%);
}
.itin-hero:not(:has(.hero-slide)) .hero-overlay {
    background: transparent;
}

/* =============================
   HERO – REFERENCE REDESIGN
============================= */
.itin-hero {
    position: relative;
    width: 100%;
    height: 480px;          /* tall full-bleed hero */
    overflow: hidden;
    background: #0d1b3e;
}

/* Sliding full-bleed background images */
.hero-slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1.4s ease;
    z-index: 0;
}
.hero-slide.active { opacity: 1; }

/* Dark bottom-heavy gradient */
.hero-grad {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(
        to bottom,
        rgba(0,0,0,0.20) 0%,
        rgba(0,0,0,0.08) 35%,
        rgba(0,0,0,0.55) 70%,
        rgba(0,0,0,0.80) 100%
    );
}

/* ── Destination pill (top-left) ── */
.hero-dest-pill {
    position: absolute;
    top: 1.4rem;
    left: 1.8rem;
    z-index: 3;
    background: rgba(255,255,255,0.18);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,0.28);
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1.2px;
    padding: 0.35rem 0.85rem;
    border-radius: 20px;
}

/* ── Pricing card (top-right) ── */
.hero-price-card {
    position: absolute;
    top: 1.2rem;
    right: 1.8rem;
    z-index: 3;
    background: rgba(255,255,255,0.14);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(255,255,255,0.22);
    border-radius: 18px;
    padding: 1rem 1.4rem;
    min-width: 200px;
    color: #fff;
    text-align: center;
}
.hpc-starting {
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 1.5px;
    color: rgba(255,255,255,0.65);
    margin-bottom: 0.2rem;
}
.hpc-price {
    font-size: 1.75rem;
    font-weight: 800;
    color: #fff;
    margin-bottom: 0.75rem;
    letter-spacing: -0.5px;
}
.hpc-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    border-top: 1px solid rgba(255,255,255,0.2);
    padding-top: 0.65rem;
}
.hpc-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}
.hpc-num {
    font-size: 1.25rem;
    font-weight: 800;
    color: #fff;
}
.hpc-label {
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 1px;
    color: rgba(255,255,255,0.55);
}
.hpc-divider {
    width: 1px;
    height: 32px;
    background: rgba(255,255,255,0.25);
}

/* ── Title box (bottom-left) ── */
.hero-title-box {
    position: absolute;
    bottom: 5.5rem;
    left: 1.8rem;
    z-index: 3;
    max-width: 55%;
}
.hero-main-title {
    font-family: 'Playfair Display', serif;
    font-size: 2.2rem;
    font-weight: 800;
    color: #fff;
    line-height: 1.2;
    text-shadow: 0 2px 16px rgba(0,0,0,0.55);
    margin: 0;
}

/* ── Thumbnail strip (bottom-center) ── */
.hero-thumb-strip {
    position: absolute;
    bottom: 1.25rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    display: flex;
    gap: 0.55rem;
    max-width: 90vw;
    overflow-x: auto;
    padding: 10px;
    scrollbar-width: none; /* Hide for Firefox */
}
.hero-thumb-strip::-webkit-scrollbar {
    display: none; /* Hide for Chrome/Safari */
}
.hero-thumb {
    width: 72px;
    height: 50px;
    border-radius: 10px;
    background-size: cover;
    background-position: center;
    cursor: pointer;
    border: 2px solid rgba(255,255,255,0.25);
    transition: border-color 0.25s, transform 0.2s;
    flex-shrink: 0;
}
.hero-thumb:hover   { transform: scale(1.06); border-color: rgba(255,255,255,0.7); }
.hero-thumb.active  { border-color: #fff; transform: scale(1.08); }

.hero-thumb {
    position: relative;
    overflow: visible;
}

.hero-thumb::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0);
    transition: background 0.3s ease;
    border-radius: inherit;
    z-index: 1;
    pointer-events: none;
}

.hero-thumb:hover::before {
    background: rgba(0,0,0,0.2);
}

.hero-thumb-remove {
    position: absolute;
    top: 4px;
    left: 4px;
    width: 20px;
    height: 20px;
    background: #ff4d4d;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: bold;
    line-height: 1;
    cursor: pointer;
    border: 2px solid #fff;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 10;
}

.hero-thumb:hover .hero-thumb-remove {
    opacity: 1;
    transform: scale(1);
}

.hero-thumb-remove:hover {
    background: #ff3333;
    transform: scale(1.15) !important;
    box-shadow: 0 6px 14px rgba(0,0,0,0.4);
}

.hero-thumb-add {
    width: 72px;
    height: 50px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    border: 2px dashed rgba(255, 255, 255, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.5rem;
    color: white;
    transition: all 0.2s;
    flex-shrink: 0;
}
.hero-thumb-add:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: white;
    transform: scale(1.06);
}

/* Global Image Search Modal */
.image-search-modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(8px);
    z-index: 3000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}
.image-search-modal-overlay.visible {
    opacity: 1;
    pointer-events: auto;
}
.image-search-modal {
    background: #f8faff;
    width: 900px;
    max-width: 95vw;
    height: 80vh;
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: scale(0.95);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.image-search-modal-overlay.visible .image-search-modal {
    transform: scale(1);
}
.ism-header {
    background: white;
    padding: 1.25rem 2rem;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.ism-title {
    font-size: 1.25rem;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -0.5px;
}
.ism-close {
    background: #f1f5f9;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    color: #64748b;
    cursor: pointer;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}
.ism-close:hover { background: #fee2e2; color: #ef4444; transform: rotate(90deg); }

.ism-search-bar {
    padding: 1rem 2rem;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    gap: 12px;
    align-items: center;
}
.ism-input-wrap {
    flex: 1; /* This makes the search bar long */
    position: relative;
    display: flex;
    align-items: center;
}
.ism-input {
    width: 100%;
    height: 44px;
    padding: 0 1rem 0 2.8rem;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 500;
    color: #1e293b;
    outline: none;
    transition: all 0.2s;
    background: white;
}
.ism-input:focus { 
    border-color: var(--accent); 
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1); 
}
.ism-search-icon {
    position: absolute;
    left: 1rem;
    font-size: 1.1rem;
    color: #94a3b8;
    pointer-events: none;
    z-index: 5;
}
.ism-type-select {
    width: 150px; /* Small fixed width for options */
    flex-shrink: 0;
    height: 44px;
    padding: 0 2rem 0 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    background: white;
    font-size: 0.9rem;
    font-weight: 600;
    color: #1e293b;
    cursor: pointer;
    outline: none;
    transition: all 0.2s;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
}
.ism-type-select:focus { 
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}
.ism-results {
    flex: 1;
    overflow-y: auto;
    padding: 2rem;
    background: #f8faff;
}
.ism-results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
}
.ism-item {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: all 0.3s;
    border: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
}
.ism-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px -4px rgba(0, 0, 0, 0.15);
    border-color: #3b82f6;
}
.ism-item img {
    width: 100%;
    height: 140px;
    object-fit: cover;
}
.ism-item-info {
    padding: 1rem;
}
.ism-item-name {
    font-size: 0.85rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.25rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.ism-item-meta {
    font-size: 0.7rem;
    color: #64748b;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 0.5px;
}

/* ========================================
   GALLERY HEADER + SEARCH PANEL
======================================== */
.gallery-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.btn-add-photos {
    background: #2563eb;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0.45rem 1rem;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
    white-space: nowrap;
}
.btn-add-photos:hover { background: #1d4ed8; transform: translateY(-1px); }

/* Empty state */
.gallery-empty {
    color: #94a3b8;
    font-size: 0.85rem;
    padding: 1rem 0;
    font-style: italic;
}

/* Remove button on gallery tile */
.gallery-tile { position: relative; }
.gallery-tile-remove {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(0,0,0,0.6);
    color: #fff;
    font-size: 0.65rem;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s;
    z-index: 2;
}
.gallery-tile:hover .gallery-tile-remove { opacity: 1; }

/* Highlight when gallery is a drop target for images */
.photo-gallery-section.gallery-drop-target {
    background: #eff6ff;
    box-shadow: 0 0 0 2px #bfdbfe inset;
}

/* ── Search panel ── */
.gallery-search-panel {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 1rem;
    margin-top: 0.75rem;
}
.gsp-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}
.gsp-title {
    font-weight: 700;
    font-size: 0.9rem;
    color: #1e293b;
}
.gsp-close {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    color: #64748b;
    padding: 0 4px;
}
.gsp-close:hover { color: #1e293b; }

.gsp-search-row {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}
.gsp-input {
    flex: 1;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.5rem 0.85rem;
    font-size: 0.85rem;
    outline: none;
    transition: border-color 0.2s;
}
.gsp-input:focus { border-color: #2563eb; }
.gsp-search-btn {
    background: #2563eb;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1rem;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}
.gsp-search-btn:hover { background: #1d4ed8; }

.gsp-loading, .gsp-empty {
    color: #64748b;
    font-size: 0.83rem;
    padding: 0.75rem 0;
}

/* Results grid — 4 columns */
.gsp-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 0.6rem;
    max-height: 380px;
    overflow-y: auto;
    padding-right: 4px;
}
.gsp-item {
    background: #fff;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: box-shadow 0.2s;
}
.gsp-item:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.10); }
.gsp-item img {
    width: 100%;
    height: 90px;
    object-fit: cover;
}
.gsp-item-name {
    font-size: 0.72rem;
    color: #475569;
    padding: 4px 6px 2px;
    flex: 1;
    line-height: 1.3;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
}
.gsp-add-btn {
    margin: 4px 6px 6px;
    background: #2563eb;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 4px 0;
    font-size: 0.73rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    text-align: center;
}
.gsp-add-btn:hover { background: #1d4ed8; }
.gsp-add-btn.added { background: #16a34a; cursor: default; }

/* ── Image search tags ── */
.gsp-info-tags {
    display: flex;
    gap: 4px;
    padding: 4px 6px 0;
    flex-wrap: wrap;
}
.gsp-tag {
    font-size: 0.6rem;
    padding: 1px 5px;
    border-radius: 4px;
    font-weight: 600;
    text-transform: uppercase;
}
.gsp-tag.region { background: #e0f2fe; color: #0369a1; } /* Blue */
.gsp-tag.type { background: #fef3c7; color: #92400e; }   /* Amber */

/* ── Type dropdown & count pill ── */
.gsp-type-select {
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    padding: 0 0.5rem;
    font-size: 0.85rem;
    background: #fff;
    cursor: pointer;
    outline: none;
    transition: border-color 0.2s;
}
.gsp-type-select:focus { border-color: #2563eb; }

.gsp-count-pill {
    background: #e2e8f0;
    color: #475569;
    font-size: 0.72rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 10px;
}
/* Landing page and package cards removed */
@media (max-width: 768px) {
    .left-panel { width: 100%; position: absolute; z-index: 100; transform: translateX(-100%); transition: transform 0.3s; }
    .left-panel.visible { transform: translateX(0); }
}

/* ========================================
   HOTEL SEARCH MODAL
   ======================================== */
.hotel-search-modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(8px);
    z-index: 3000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}
.hotel-search-modal-overlay.visible {
    opacity: 1;
    pointer-events: auto;
}
.hotel-search-modal {
    background: #f8faff;
    width: 1000px;
    max-width: 95vw;
    height: 85vh;
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: scale(0.95);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.hotel-search-modal-overlay.visible .hotel-search-modal {
    transform: scale(1);
}

.hsm-header {
    background: white;
    padding: 1.5rem 2rem;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.hsm-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: #1e293b;
}
.hsm-close {
    background: #f1f5f9;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: #64748b;
    cursor: pointer;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}
.hsm-close:hover { background: #e2e8f0; color: #1e293b; }

.hsm-search-bar {
    padding: 1.5rem 2rem;
    background: white;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    gap: 1rem;
}
.hsm-input-wrap {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
}
.hsm-input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 2.8rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    background: white;
    color: #0f172a;
    outline: none;
    transition: all 0.2s;
}
.hsm-input:focus { 
    border-color: var(--accent); 
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1); 
}
.hsm-search-icon {
    position: absolute;
    left: 1.2rem;
    font-size: 1.2rem;
    color: #94a3b8;
}
.hsm-search-btn {
    padding: 0 1.5rem;
    background: #3b82f6;
    color: white;
    border: none;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}
.hsm-search-btn:hover { background: #2563eb; }

.hsm-results {
    flex: 1;
    overflow-y: auto;
    padding: 2rem;
    background: #f8faff;
}
.hsm-results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.hsm-item {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transition: all 0.3s;
    border: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
}
.hsm-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px -4px rgba(0, 0, 0, 0.15);
    border-color: #3b82f6;
}
.hsm-item-image {
    position: relative;
    width: 100%;
    height: 180px;
}
.hsm-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.hsm-item-stars {
    position: absolute;
    bottom: 0.75rem;
    left: 0.75rem;
    background: rgba(255,255,255,0.9);
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.75rem;
    backdrop-filter: blur(4px);
}

.hsm-item-info {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.hsm-item-name {
    font-weight: 700;
    font-size: 1.05rem;
    color: #1e293b;
}
.hsm-item-meta {
    font-size: 0.85rem;
    color: #64748b;
}
.hsm-add-btn {
    margin-top: 0.5rem;
    padding: 0.75rem;
    background: #eff6ff;
    color: #2563eb;
    border: 1px solid #bfdbfe;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}
.hsm-add-btn:hover {
    background: #2563eb;
    color: white;
    border-color: #2563eb;
}
.hsm-add-btn.added {
    background: #f0fdf4;
    color: #16a34a;
    border-color: #bbf7d0;
    cursor: default;
}

.btn-add-hotels {
    padding: 0.5rem 1rem;
    background: white;
    color: #2563eb;
    border: 1.5px solid #2563eb;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}
.btn-add-hotels:hover {
    background: #eff6ff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.15);
}

.hc-image-wrap {
    position: relative;
    overflow: hidden;
}

.hc-remove {
    position: absolute;
    top: 10px;
    left: 10px;
    width: 28px;
    height: 28px;
    background: #ef4444;
    color: white;
    border: 2px solid white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.2rem;
    font-weight: bold;
    z-index: 10;
    opacity: 0;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.hotel-card:hover .hc-remove {
    opacity: 1;
    transform: scale(1.1);
}

.hc-remove:hover {
    background: #dc2626;
    transform: scale(1.2) !important;
}
/* ========================================
   PACKAGE SEARCH MODAL
   ======================================== */
.package-search-modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(10px);
    z-index: 4000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}
.package-search-modal-overlay.visible {
    opacity: 1;
    pointer-events: auto;
}
.package-search-modal {
    background: #f8faff;
    width: 1100px;
    max-width: 95vw;
    height: 90vh;
    border-radius: 32px;
    box-shadow: 0 40px 100px -20px rgba(0, 0, 0, 0.6);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: translateY(20px) scale(0.98);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.package-search-modal-overlay.visible .package-search-modal {
    transform: translateY(0) scale(1);
}

.psm-header {
    background: white;
    padding: 1.5rem 3rem;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.psm-title {
    font-size: 1.6rem;
    font-weight: 800;
    color: #1e293b;
    letter-spacing: -0.5px;
}
.psm-close {
    background: #f1f5f9;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: #64748b;
    cursor: pointer;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}
.psm-close:hover { background: #fee2e2; color: #ef4444; transform: rotate(90deg); }

.psm-search-bar {
    padding: 1.5rem 3rem;
    background: white;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    gap: 1.5rem;
}
.psm-input-wrap {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
}
.psm-input {
    width: 100%;
    padding: 0.85rem 1.5rem 0.85rem 3.2rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    color: #0f172a;
    outline: none;
    transition: all 0.2s;
    background: white;
}
.psm-input:focus { 
    border-color: var(--accent); 
    background: white; 
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1); 
}
.psm-search-icon {
    position: absolute;
    left: 1.25rem;
    font-size: 1.4rem;
    color: #94a3b8;
}
.psm-search-btn {
    padding: 0 2rem;
    background: #3b82f6;
    color: white;
    border: none;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s;
}
.psm-search-btn:hover { background: #2563eb; transform: translateY(-1px); box-shadow: 0 8px 20px rgba(37, 99, 235, 0.2); }

.psm-results {
    flex: 1;
    overflow-y: auto;
    padding: 2.5rem 3rem;
    background: #f8faff;
}
.psm-results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
}


/* =============================
   ENGINE INTEGRATION STYLES (Ported from itinerary.html)
   ============================= */

      *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
      :root {
        --gold: #c9a84c; --gold-light: #f0d080;
        --navy: #0b1829; --navy-card: #112035;
        --navy-mid: #18304a; --navy-border: #1e3a52;
        --teal: #00c9a7; --sky: #38bdf8;
        --white: #f8faff; --muted: #7a9ab5;
        --radius: 14px;
      }
      html { scroll-behavior: smooth; }
      body { font-family: 'Inter', sans-serif; background: var(--navy); color: var(--white); min-height: 100vh; }

      /* ── HEADER ── */
      header {
        background: linear-gradient(135deg, var(--navy-card) 0%, #0d1f38 100%);
        border-bottom: 1px solid var(--navy-border);
        padding: 0 40px; height: 64px;
        position: sticky; top: 0; z-index: 200;
        display: flex; align-items: center; gap: 16px;
      }
      .logo { display: flex; align-items: center; gap: 10px; }
      .logo-icon { width: 36px; height: 36px; background: linear-gradient(135deg,var(--gold),var(--gold-light)); border-radius:10px; display:grid; place-items:center; font-size:18px; }
      .logo-text { font-size: 18px; font-weight: 700; }
      .logo-text span { color: var(--gold); }
      .header-sub { font-size: 12px; color: var(--muted); margin-top: 2px; }
      .header-right { margin-left: auto; }
      .badge-api { font-size:11px; background:rgba(0,201,167,.15); color:var(--teal); border:1px solid rgba(0,201,167,.3); border-radius:20px; padding:3px 10px; }

      /* ── LAYOUT ── */
      .app { display: grid; grid-template-columns: 320px 1fr; min-height: calc(100vh - 64px); }

      /* ── SIDEBAR ── */
      .sidebar {
        background: var(--navy-card); border-right: 1px solid var(--navy-border);
        padding: 24px 20px; overflow-y: auto;
        position: sticky; top: 64px; height: calc(100vh - 64px);
      }
      .sidebar h2 { font-size: 15px; font-weight: 700; margin-bottom: 18px; }
      .form-group { margin-bottom: 14px; }
      label { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); display: block; margin-bottom: 5px; }
      input, select { width: 100%; padding: 9px 12px; font-size: 13px; font-family: inherit; background: var(--navy-mid); border: 1px solid var(--navy-border); border-radius: 9px; color: var(--white); outline: none; transition: border-color .2s, box-shadow .2s; }
      input:focus, select:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(201,168,76,.14); }
      .row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
      .themes-grid { display: flex; flex-wrap: wrap; gap: 6px; }
      .theme-chip { padding: 4px 10px; border-radius:20px; font-size:11px; font-weight:600; cursor:pointer; border:1.5px solid var(--navy-border); background:var(--navy-mid); color:var(--muted); transition:all .2s; user-select:none; }
      .theme-chip.active { border-color:var(--gold); color:var(--gold); background:rgba(201,168,76,.1); }
      .btn-generate { width:100%; padding:12px; border:none; border-radius:11px; cursor:pointer; font-size:14px; font-weight:700; font-family:inherit; background:linear-gradient(135deg,var(--gold) 0%,var(--gold-light) 100%); color:#0b1829; margin-top:8px; transition:transform .15s, box-shadow .2s; position:relative; overflow:hidden; }
      .btn-generate:hover { transform:translateY(-1px); box-shadow:0 6px 24px rgba(201,168,76,.4); }
      .btn-generate.loading::after { content:''; position:absolute; inset:0; background:rgba(255,255,255,.3); animation:shimmer 1s infinite linear; }
      @keyframes shimmer { 0%{transform:translateX(-100%)} 100%{transform:translateX(100%)} }
      .divider { border:none; border-top:1px solid var(--navy-border); margin:16px 0; }
      .error-box { display:none; background:rgba(239,68,68,.08); border:1px solid rgba(239,68,68,.3); border-radius:var(--radius); padding:12px 16px; color:#fca5a5; font-size:12px; margin-top:10px; }
      .error-box.show { display:block; }

      /* ── MAIN ── */
      .main { padding: 0; overflow-y: auto; position: relative; }

      /* Empty state */
      .empty-state { display:flex; flex-direction:column; align-items:center; justify-content:center; height:70vh; gap:14px; text-align:center; }
      .empty-state .icon { font-size:60px; opacity:.25; }
      .empty-state p { color:var(--muted); font-size:15px; max-width:300px; }

      /* Loader */
      .loader { display:none; flex-direction:column; align-items:center; justify-content:center; height:70vh; gap:18px; }
      .loader.show { display:flex; }
      .spinner { width:48px; height:48px; border-radius:50%; border:3px solid var(--navy-border); border-top-color:var(--gold); animation:spin .8s linear infinite; }
      @keyframes spin { to { transform:rotate(360deg); } }
      .loader p { color:var(--muted); font-size:13px; }

      /* Result wrapper */
      #result { display:none; }

      /* ── TRIP HERO (top) ── */
      .trip-hero {
        background: linear-gradient(135deg, var(--navy-card) 0%, var(--navy-mid) 100%);
        border-bottom: 1px solid var(--navy-border);
        padding: 28px 36px 24px;
        position: relative; overflow: hidden;
      }
      .trip-hero::before { content:''; position:absolute; inset:0; background:radial-gradient(ellipse at top right, rgba(201,168,76,.13) 0%, transparent 60%); pointer-events:none; }
      .trip-title { font-size:24px; font-weight:800; margin-bottom:4px; }
      .trip-title span { color:var(--gold); }
      .trip-meta { display:flex; gap:10px; flex-wrap:wrap; margin-top:12px; }
      .trip-meta-item { display:flex; align-items:center; gap:7px; font-size:12px; color:var(--muted); background:rgba(255,255,255,.04); border:1px solid var(--navy-border); border-radius:7px; padding:5px 11px; }
      .trip-meta-item strong { color:var(--white); }

      /* highlights row */
      .section-label { font-size:11px; font-weight:700; text-transform:uppercase; letter-spacing:.7px; color:var(--muted); margin-bottom:10px; }
      .highlights-row { display:flex; gap:8px; flex-wrap:wrap; padding:0 36px 22px; margin-top:18px; }
      .highlight-chip { display:flex; align-items:center; gap:5px; padding:5px 12px; background:rgba(56,189,248,.07); border:1px solid rgba(56,189,248,.2); border-radius:24px; font-size:11px; font-weight:600; color:var(--sky); animation:fadeUp .4s ease both; }
      @keyframes fadeUp { from{opacity:0;transform:translateY(6px)} to{opacity:1;transform:translateY(0)} }

      /* Mother Package Dropdown & Icon */
      .btn-icon-mother {
          background: #f0f9ff;
          border: 1px solid #bae6fd;
          color: #0369a1;
      }
      .btn-icon-mother:hover {
          background: #e0f2fe;
          border-color: #7dd3fc;
      }

      .mother-package-dropdown {
          width: 500px;
          background: #ffffff; border: 1px solid #e2e8f0; border-radius: 14px;
          box-shadow: 0 10px 60px rgba(0,0,0,0.15); z-index: 2000; overflow: hidden;
          display: flex; flex-direction: column; animation: fadeUp 0.3s ease both; max-height: 550px;
      }
      .mp-search-container {
          padding: 12px 16px;
          background: #ffffff;
          border-bottom: 1px solid #f1f5f9;
      }
      .mp-search-input {
          width: 100%;
          padding: 10px 14px;
          background: #f8fafc;
          border: 1px solid #e2e8f0;
          border-radius: 10px;
          font-size: 13px;
          outline: none;
          color: #1e293b;
          transition: all 0.2s;
      }
      .mp-search-input::placeholder {
          color: #94a3b8;
      }
      .mp-search-input:focus {
          border-color: #38bdf8;
          background: #fff;
          box-shadow: 0 0 0 4px rgba(56, 189, 248, 0.1);
          color: #0f172a;
      }
      .mp-item .mp-title {
          font-size: 13px;
          font-weight: 700;
          color: #0f172a;
          white-space: normal;
          line-height: 1.4;
          margin-bottom: 4px;
          overflow: visible;
      }
      .mp-item .mp-desc {
          font-size: 12px;
          color: #475569;
          display: block;
          white-space: normal;
          overflow: visible;
          text-overflow: unset;
      }
      .mp-header {
          padding: 12px 16px; background: #f8fafc; border-bottom: 1px solid #e2e8f0;
          display: flex; justify-content: space-between; align-items: center; font-size: 11px; font-weight: 700; color: #64748b; text-transform: uppercase; letter-spacing: 0.5px;
      }
      .mp-close { background: none; border: none; font-size: 18px; color: #94a3b8; cursor: pointer; line-height: 1; }
      .mp-list { overflow-y: auto; padding: 8px; }
      .mp-item {
          display: flex; gap: 12px; padding: 10px; border-radius: 8px; cursor: pointer; transition: all 0.2s; border: 1px solid transparent; margin-bottom: 4px;
      }
      .mp-item:hover { background: #f0f9ff; border-color: #bae6fd; }
      .mp-img { width: 60px; height: 60px; border-radius: 6px; object-fit: cover; flex-shrink: 0; }
      .mp-no-img { width: 60px; height: 60px; border-radius: 6px; background: #f1f5f9; display: grid; place-items: center; flex-shrink: 0; font-size: 20px; }
      .mp-info { flex: 1; min-width: 0; }
      .mp-title { font-size: 12px; font-weight: 700; color: #0f172a; margin-bottom: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
      .mp-desc { font-size: 11px; color: #64748b; line-height: 1.4;    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical; overflow: hidden; }
      .loading-mp, .no-mp-data, .error-mp { padding: 30px; text-align: center; color: #94a3b8; font-size: 0.8rem; }

      /* ── HOTEL DETAIL SECTION ── */
      .hotel-section { padding: 0 36px; margin-bottom:0; }
      .hotel-detail-card {
        background: var(--navy-card);
        border: 1px solid var(--navy-border);
        border-radius: var(--radius);
        overflow: hidden;
        animation: fadeUp .5s ease both;
      }
      .hotel-detail-top {
        display: grid; grid-template-columns: 1fr auto;
        gap: 24px; padding: 24px 28px;
        border-bottom: 1px solid var(--navy-border);
      }
      .hotel-badge-row { display:flex; align-items:center; gap:12px; margin-bottom:10px; }
      .hotel-icon-big { width:52px; height:52px; border-radius:12px; background:linear-gradient(135deg,var(--gold),var(--gold-light)); display:grid; place-items:center; font-size:26px; flex-shrink:0; }
      .hotel-name-big { font-size:20px; font-weight:800; }
      .hotel-stars-big { color:var(--gold); font-size:16px; letter-spacing:3px; }
      .hotel-sub { font-size:12px; color:var(--muted); margin-top:2px; }
      .hotel-price-block { text-align:right; }
      .hotel-price-block .rate { font-size:26px; font-weight:800; color:var(--gold); }
      .hotel-price-block .rate-label { font-size:11px; color:var(--muted); }
      .hotel-price-block .ta { font-size:12px; color:var(--white); margin-top:4px; }
      /* detail grid rows */
      .hotel-detail-grid {
        display: grid; grid-template-columns: 1fr 1fr;
        gap: 0;
      }
      .hotel-detail-cell {
        padding: 14px 28px;
        border-bottom: 1px solid var(--navy-border);
        border-right: 1px solid var(--navy-border);
      }
      .hotel-detail-cell:nth-child(even) { border-right: none; }
      .hotel-detail-cell:nth-last-child(-n+2) { border-bottom: none; }
      .hd-label { font-size:9px; font-weight:700; text-transform:uppercase; letter-spacing:.7px; color:var(--muted); margin-bottom:4px; }
      .hd-value { font-size:13px; font-weight:600; color:var(--white); display:flex; align-items:center; gap:6px; }
      .hd-value a { color:var(--sky); text-decoration:none; font-size:12px; }
      .hd-value a:hover { text-decoration:underline; }
      /* amenities row */
      .hotel-amenities { padding: 14px 28px; display:flex; flex-wrap:wrap; gap:8px; border-top: 1px solid var(--navy-border); }
      .amenity-chip { font-size:11px; padding:3px 10px; border-radius:20px; background:rgba(56,189,248,.07); color:var(--sky); border:1px solid rgba(56,189,248,.18); }

      .hotel-day-dropdown { display: none; }
      .hotel-day-dropdown.show { display: block; }

      /* ── STICKY DAY NAV (White Theme) ── */
      .day-nav {
        position: sticky; top: 0; z-index: 150;
        background: rgba(255, 255, 255, 0.98); backdrop-filter: blur(12px);
        border-bottom: 2px solid #e2e8f0;
        display: flex; gap: 8px; padding: 12px 36px; flex-wrap: nowrap; overflow-x: auto;
        scrollbar-width: none;
      }
      .day-nav::-webkit-scrollbar { display: none; }
      .day-nav-btn {
        padding: 8px 18px; border-radius: 8px; cursor: pointer; font-size: 13px; font-weight: 700;
        background: #f8fafc; border: 1.5px solid #e2e8f0;
        color: #64748b; white-space: nowrap; transition: all .2s; flex-shrink: 0;
      }
      .day-nav-btn:hover { border-color: var(--accent); color: var(--accent); background: white; }
      .day-nav-btn.active { background: var(--accent); border-color: var(--accent); color: white; }

      /* ── DAY SECTIONS (White Card Flow) ── */
      .days-flow { padding: 36px 36px 48px; position: relative; }
      .itin-timeline-line {
        position: absolute;
        left: 58px;
        top: 60px;
        bottom: 0;
        width: 1px;
        background: #e2e8f0;
        z-index: 1;
      }
      .itin-card-wrapper {
        display: flex;
        margin-bottom: 24px;
        position: relative;
        font-family: 'Inter', sans-serif;
        z-index: 10;
        scroll-margin-top: 100px;
      }
      .itin-day-pill {
        width: 44px;
        height: 52px;
        background: #0b459e;
        border-radius: 8px;
        color: white;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        line-height: 1;
        box-shadow: 0 4px 6px rgba(0,0,0,0.1);
        position: absolute;
        left: 0;
        top: 0;
        z-index: 10;
      }
      .itin-day-pill .dw { font-size: 9px; font-weight: 700; text-transform: uppercase; margin-bottom: 3px; }
      .itin-day-pill .dn { font-size: 18px; font-weight: 800; }

      .itin-card {
        margin-left: 22px;
        background: white;
        border: 1px solid #0b459e;
        border-radius: 12px;
        flex: 1;
        overflow: hidden;
        box-shadow: 0 4px 12px rgba(0,0,0,0.04);
      }
      .itin-card-header {
        padding: 18px 24px 18px 44px;
        border-bottom: 1px solid #e2e8f0;
        display: flex;
        justify-content: space-between;
        align-items: center;
        cursor: pointer;
      }
      .itin-card-title {
        color: #0b459e;
        font-size: 16px;
        font-weight: 800;
        line-height: 1.3;
      }
      .itin-chevron {
        background: #0b459e;
        color: white;
        width: 24px;
        height: 24px;
        border-radius: 6px;
        display: flex;
        align-items: center;
        justify-content: center;
      }
      .itin-chevron svg { width: 14px; height: 14px; }
      .itin-card-body {
        padding: 24px;
        display: flex;
        flex-direction: column;
        gap: 12px;
      }
      .itin-item {
        background: #f8fafc;
        border-radius: 8px;
        padding: 14px 18px;
        display: flex;
        align-items: flex-start;
        gap: 14px;
        transition: background 0.2s;
      }
      .itin-item:hover { background: #f1f5f9; }
      /* ── Activity type badge styles ── */
      .act-badge {
        display: inline-flex; align-items: center; gap: 4px;
        font-size: 10px; font-weight: 800; text-transform: uppercase;
        letter-spacing: 0.6px; padding: 2px 8px; border-radius: 20px;
        margin-bottom: 5px;
      }
      .act-badge-activity  { background: rgba(59,130,246,.12); color: #3b82f6; border: 1px solid rgba(59,130,246,.25); }
      .act-badge-photostop { background: rgba(16,185,129,.12); color: #10b981; border: 1px solid rgba(16,185,129,.25); }
      .act-badge-drivethru { background: rgba(245,158,11,.12); color: #f59e0b; border: 1px solid rgba(245,158,11,.25); }

      .act-meta-row { display:flex; flex-wrap:wrap; gap:6px; margin-top:5px; }
      .act-meta-chip { font-size:10px; color:#64748b; background:#f1f5f9; border-radius:4px; padding:1px 6px; }

      .itin-item.type-activity  { border-left: 3px solid #3b82f6; }
      .itin-item.type-photostop { border-left: 3px solid #10b981; }
      .itin-item.type-drivethru { border-left: 3px solid #f59e0b; }

      .itin-icon.type-activity  { background: #eff6ff; color: #3b82f6; }
      .itin-icon.type-photostop { background: #ecfdf5; color: #10b981; }
      .itin-icon.type-drivethru { background: #fffbeb; color: #f59e0b; }
      .itin-icon {
        width: 24px;
        height: 24px;
        border-radius: 6px;
        display: flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
        margin-top: -2px;
      }
      .itin-icon svg { width: 12px; height: 12px; }
      .itin-content {
        color: #475569;
        font-size: 13px;
        line-height: 1.6;
        flex: 1;
      }
      .itin-title {
        color: #0b459e;
        font-weight: 700;
      }
      .itin-subhead {
        color: #0b459e;
        font-size: 13px;
        font-weight: 700;
        margin: 12px 0 4px;
      }
      .itin-btn-add {
        background: transparent;
        border: 1px dashed #cbd5e1;
        color: #0b459e;
        padding: 12px;
        border-radius: 8px;
        font-size: 12px;
        font-weight: 700;
        cursor: pointer;
        transition: all 0.2s;
        margin-top: 8px;
      }
      .itin-btn-add:hover {
        background: #f8fafc;
        border-color: #94a3b8;
      }

      /* ── COST + TIPS ── */
      .bottom-sections { padding: 0 36px 48px; display:grid; grid-template-columns:1fr 1fr; gap:20px; margin-top:32px; }
      .card-section { background:var(--navy-card); border:1px solid var(--navy-border); border-radius:var(--radius); padding:22px; }
      .cost-grid { display:grid; grid-template-columns:1fr 1fr; gap:14px; margin-top:14px; }
      .cost-item { text-align:center; }
      .cost-item .val { font-size:18px; font-weight:800; color:var(--gold); }
      .cost-item .lbl { font-size:10px; color:var(--muted); margin-top:2px; }
      .cost-note { font-size:10px; color:var(--muted); margin-top:14px; padding-top:12px; border-top:1px solid var(--navy-border); }
      .tips-list { display:flex; flex-direction:column; gap:8px; margin-top:14px; }
      .tip-item { font-size:12px; color:var(--muted); line-height:1.5; padding:9px 12px; background:rgba(255,255,255,.03); border-radius:7px; }

      /* ── A* ROUTE MAP ── */
      .astar-section { padding: 0 36px 28px; }
      .astar-map-card {
        background: var(--navy-card); border: 1px solid var(--navy-border);
        border-radius: var(--radius); overflow: hidden;
        animation: fadeUp .5s ease both;
      }
      .astar-map-header {
        display: flex; align-items: center; justify-content: space-between;
        padding: 16px 22px; border-bottom: 1px solid var(--navy-border);
      }
      .astar-map-title { font-size: 13px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
      .astar-badge { font-size: 10px; font-weight: 700; padding: 2px 8px; border-radius: 20px;
        background: linear-gradient(135deg,var(--gold),var(--gold-light)); color: #0b1829; }
      .astar-legend { display:flex; gap:10px; }
      .legend-item { display:flex; align-items:center; gap:4px; font-size:10px; color:var(--muted); }
      .legend-dot { width:8px; height:8px; border-radius:50%; flex-shrink:0; }
      .legend-dot.airport { background:var(--gold); }
      .legend-dot.hotel   { background:var(--teal); }
      .legend-dot.activity{ background:var(--sky); }
      #routeMapSvg { display:block; width:100%; background:var(--navy); cursor:crosshair; }
      /* Route Stats bar */
      .route-stats {
        display: flex; gap: 0;
        border-top: 1px solid var(--navy-border);
      }
      .route-stat {
        flex: 1; padding: 12px 18px; text-align:center;
        border-right: 1px solid var(--navy-border);
      }
      .route-stat:last-child { border-right: none; }
      .route-stat .rsv { font-size: 18px; font-weight: 800; color: var(--gold); }
      .route-stat .rsl { font-size: 10px; color: var(--muted); margin-top: 2px; }
      /* Tooltip */
      #mapTooltip {
        position: fixed; pointer-events:none; z-index: 999;
        background: rgba(11,24,41,.97); border: 1px solid var(--navy-border);
        border-radius: 8px; padding: 7px 12px; font-size: 11px;
        color: var(--white); max-width: 220px; display:none;
        box-shadow: 0 4px 20px rgba(0,0,0,.5);
      }
      #mapTooltip strong { color:var(--gold); display:block; margin-bottom:2px; }

      /* ── MODAL ── */
      .modal-overlay {
        position: fixed; top: 0; left: 0; right: 0; bottom: 0;
        background: rgba(11,24,41,0.85); backdrop-filter: blur(8px);
        z-index: 2000; display: none; align-items: center; justify-content: center;
        opacity: 0; transition: opacity 0.2s;
      }
      .modal-overlay.show { display: flex; opacity: 1; }
      .modal-card {
    background: #ffffff; 
    width: 95%; 
    max-width: 700px; 
    height: 85vh;
    border-radius: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4); 
    display: flex; 
    flex-direction: column;
    overflow: hidden;
    border: none;
    animation: modalSlideUp 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-header {
    background: #0f172a; /* Rich Navy */
    padding: 22px 30px; 
    display: flex; 
    justify-content: space-between; 
    align-items: center;
}

.modal-title { 
    font-size: 16px; 
    font-weight: 800; 
    color: #f8fafc; 
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.modal-close {
    cursor: pointer; 
    font-size: 24px; 
    color: #94a3b8;
    background: none; 
    border: none; 
    transition: all 0.2s; 
    padding: 0;
    line-height: 1;
}

.modal-close:hover { 
    color: #ffffff; 
    transform: rotate(90deg);
}

.modal-body { 
    padding: 0; 
    display: flex; 
    flex-direction: column; 
    flex: 1; 
    overflow: hidden;
    background: #f8fafc;
}

.leads-list-scroll {
    flex: 1;
    padding: 24px;
    padding-bottom: 80px; /* Extra bottom padding to prevent clipping of shadows/animations */
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
    position: relative;
}

.el-select-wrapper {
    flex: 1;
    position: relative;
}
      .modal-footer {
        padding: 16px 24px; border-top: 1px solid var(--navy-border);
        display: flex; justify-content: flex-end; gap: 12px;
      }
      .modal-search {
        width: 100%; background: rgba(0,0,0,0.2); border: 1px solid var(--navy-border);
        color: var(--white); border-radius: 8px; padding: 12px 16px; font-size: 14px;
        margin-bottom: 16px; outline: none; transition: border-color 0.2s;
      }
      .modal-search:focus { border-color: var(--gold); }
      .search-result-item {
--

          /* Leaflet Customizations */
          .leaflet-popup-content-wrapper { background: var(--white); border-radius: 12px; box-shadow: 0 4px 12px rgba(0,0,0,0.3); }
          .leaflet-popup-tip { background: var(--white); }
        
      }

/* Add these styles for suggestions */
.suggestions-container {
    margin: 12px 0;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    border-left: 3px solid #38bdf8;
}

.suggestions-title {
    font-size: 12px;
    color: #94a3b8;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.suggestions-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.suggestion-chip {
    background: rgba(56, 189, 248, 0.1);
    border: 1px solid rgba(56, 189, 248, 0.2);
    color: #38bdf8;
    padding: 8px 16px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.suggestion-chip:hover {
    background: rgba(56, 189, 248, 0.2);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(56, 189, 248, 0.2);
}

.suggestion-chip:before {
    content: "💡";
    font-size: 14px;
} 

/* LEAD MANAGEMENT AREA */
.expert-leads-container {
    padding: 16px;
    border-bottom: 1px solid #e2e8f0;
    background: #f8fafc;
    animation: fadeIn 0.3s ease;
}

.modal-card {
    background: #ffffff; 
    width: 95%; 
    max-width: 650px; 
    max-height: 85vh;
    border-radius: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25); 
    display: flex; 
    flex-direction: column;
    overflow: hidden;
    animation: modalSlideUp 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes modalSlideUp {
    from { opacity: 0; transform: translateY(20px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.expert-lead-header {
    background: #ffffff;
    padding: 24px 30px;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    flex-direction: column;
    gap: 18px;
    box-shadow: 0 4px 6px -4px rgba(0,0,0,0.05);
}

.el-select {
    flex: 1; 
    padding: 12px 18px; 
    background: #f8fafc; 
    border: 1px solid #e2e8f0;
    border-radius: 12px; 
    font-size: 14.5px; 
    font-weight: 500; 
    font-family: inherit;
    color: #0f172a; 
    outline: none; 
    transition: all 0.3s ease;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2338bdf8' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 44px;
}

.el-select:hover {
    border-color: #cbd5e1;
    background-color: #f1f5f9;
}

.el-select:focus { 
    border-color: #38bdf8; 
    background-color: #ffffff;
    box-shadow: 0 0 0 4px rgba(56, 189, 248, 0.15); 
}

.el-search-container {
    position: relative;
    display: flex;
    align-items: center;
}

.el-search-input {
    width: 100%;
    padding: 14px 16px 14px 48px;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    font-size: 15px;
    background: #f1f5f9;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    color: #0f172a;
    font-family: inherit;
}

.el-search-input::placeholder {
    color: #94a3b8;
    font-weight: 450;
}

.el-search-input:hover {
    background: #e2e8f0;
}

.el-search-input:focus {
    outline: none;
    background: #ffffff;
    border-color: #38bdf8;
    box-shadow: 0 10px 15px -3px rgba(37, 99, 235, 0.1), 0 4px 6px -2px rgba(37, 99, 235, 0.05);
}

.el-search-icon {
    position: absolute;
    left: 16px;
    color: #38bdf8;
    pointer-events: none;
    transition: transform 0.3s ease;
}

.el-search-input:focus + .el-search-icon {
    transform: scale(1.1);
}

.el-select-row {
    display: flex;
    gap: 12px;
}

.el-select {
    flex: 1;
}

/* Scroll area for lead list in modal */
.leads-list-scroll {
    min-height: 200px;
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 transparent;
}
.leads-list-scroll::-webkit-scrollbar { width: 6px; }
.leads-list-scroll::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 6px; }

.lead-card {
    padding: 18px; 
    background: white; 
    border: 1px solid #e2e8f0; 
    border-radius: 16px;
    cursor: pointer; 
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); 
    position: relative;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    animation: fadeInLead 0.4s ease-out forwards;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

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

.lead-card:hover {
    border-color: #38bdf8; 
    background: #ffffff; 
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(56, 189, 248, 0.1), 0 10px 10px -5px rgba(56, 189, 248, 0.04);
}

.lead-card.active { 
    border-color: #38bdf8; 
    background: #f0f9ff; 
    box-shadow: 0 0 0 2px #38bdf8; 
}

.lead-card .l-name { 
    font-weight: 800; 
    font-size: 17px; 
    color: #0f172a; 
    margin-bottom: 2px;
    letter-spacing: -0.3px;
}

.lead-card .l-dest { 
    font-size: 13.5px; 
    color: #38bdf8; 
    font-weight: 600; 
    display: flex; 
    align-items: center; 
    gap: 6px; 
}

.lead-card .l-grid { 
    display: grid; 
    grid-template-columns: repeat(2, 1fr); 
    gap: 12px; 
    margin-top: 16px; 
}

.lead-card .l-item { 
    font-size: 12px; 
    color: #64748b; 
    display: flex; 
    align-items: center; 
    gap: 8px;
    background: #f8fafc;
    padding: 6px 10px;
    border-radius: 8px;
}

.lead-card .l-item b {
    color: #1e293b;
}

.lead-card .l-meta { 
    font-size: 11px; 
    color: #94a3b8; 
    margin-top: 16px; 
    padding-top: 14px; 
    border-top: 1px solid #f1f5f9; 
    display: flex; 
    justify-content: space-between;
    align-items: center; 
}

.l-meta-left {
    display: flex;
    gap: 12px;
    align-items: center;
}

.leads-status-tag {
    font-size: 10px; 
    text-transform: uppercase; 
    letter-spacing: 0.8px; 
    font-weight: 800;
    padding: 4px 10px; 
    border-radius: 20px; 
    background: #f1f5f9; 
    color: #475569;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.5);
}

.ls-warm { background: #fee2e2; color: #dc2626; border: 1px solid #fecaca; }
.ls-new { background: #dcfce7; color: #16a34a; border: 1px solid #bbf7d0; }
.ls-inprogress { background: #e0f2fe; color: #0284c7; border: 1px solid #bae6fd; }
.ls-nurture { background: #fef9c3; color: #ca8a04; border: 1px solid #fef08a; }

.no-leads-msg {
    text-align: center; padding: 40px 20px; color: #94a3b8; font-size: 13px;
    background: white; border: 1px dashed #e2e8f0; border-radius: 12px;
}
.loading-leads { text-align: center; padding: 20px; font-size: 12px; color: #64748b; }
.lead-btn-apply {
    margin-top: 12px; width: 100%; padding: 10px; font-size: 13px;
    background: #0f172a; color: white; border: none; border-radius: 10px;
    font-weight: 700; cursor: pointer; transition: all 0.2s;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.2);
}
.lead-btn-apply:hover { background: #1e293b; transform: scale(1.02); }
/* Mini Icon Button for inline edits (e.g. taxes) */
.btn-icon-mini {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    cursor: pointer;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    color: #94a3b8;
    opacity: 0;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    vertical-align: middle;
    margin-left: 6px;
    padding: 0;
}

.tc-tax-row:hover .btn-icon-mini {
    opacity: 0.7;
}

.tc-tax-row:hover .btn-icon-mini:hover {
    background: #eff6ff;
    color: #2563eb;
    opacity: 1;
    transform: scale(1.1);
}

.btn-icon-mini svg {
    display: block;
}
/* Typing Indicator */
.typing-indicator {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 0;
}

.typing-indicator span {
    width: 6px;
    height: 6px;
    background-color: var(--text-secondary);
    border-radius: 50%;
    opacity: 0.4;
    animation: typing 1s infinite alternate;
}

.typing-indicator span:nth-child(2) { animation-delay: 0.2s; }
.typing-indicator span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typing {
    from { transform: translateY(0); opacity: 0.4; }
    to { transform: translateY(-4px); opacity: 1; }
}
