/* ============================================================
   MON PARIS — AI Travel Planner
   Classic Design with Messenger Chat
   ============================================================ */

:root {
  --cream: #fdfaf5;
  --ivory: #ffffff;
  --ivory-dark: #f0eadd;
  --midnight-blue: #0f172a;
  --warm-brown: #2c2520;
  --gold: #c5a059;
  --gold-light: #e6c887;
  --gold-glow: #e2b35a;
  --gold-grad: linear-gradient(135deg, #d4af37 0%, #fff2cd 50%, #d4af37 100%);
  --text-main: #1f2937;
  --text-muted: #6b7280;
  --white: #ffffff;
  
  --cat-sight:  #6b8e23; 
  --cat-resto:  #bc8f8f; 
  --cat-cafe:   #a67d3d;
  --cat-bakery: #c19a6b;
  --cat-act:    #708090;

  --ff-serif: 'Playfair Display', Georgia, serif;
  --ff-body:  'Cormorant Garamond', Georgia, serif;
  --ff-ui:    'Outfit', sans-serif;

  --radius-lg: 16px;
  --shadow-md: 0 12px 45px rgba(15, 23, 42, 0.08);
  --shadow-gold: 0 8px 30px rgba(197, 160, 89, 0.25);
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body {
  background-color: var(--cream);
  color: var(--text-main);
  font-family: var(--ff-body);
  font-size: 17px;
  line-height: 1.7;
}

body::after {
  content: '';
  position: fixed; inset: 0;
  background-image: url("https://www.transparenttextures.com/patterns/natural-paper.png");
  opacity: 0.12; pointer-events: none; z-index: -1;
}

/* ===================== HEADER (RESTORED) ===================== */
.site-header {
  background: var(--midnight-blue);
  background-image: linear-gradient(rgba(15, 23, 42, 0.6), rgba(15, 23, 42, 0.8)), 
                    url('https://images.unsplash.com/photo-1499856871958-5b9627545d1a?auto=format&fit=crop&q=80&w=2020');
  background-size: cover; background-position: center 40%;
  background-attachment: fixed; /* Parallax effect */
  text-align: center; padding: 10rem 2rem 8rem; position: relative; overflow: hidden;
}

.header-eyebrow { color: var(--gold-light); font-family: var(--ff-ui); font-size: 0.85rem; letter-spacing: 0.3em; text-transform: uppercase; margin-bottom: 1rem; animation: fadeUp 1s ease both; }
.header-title { font-family: var(--ff-serif); font-size: clamp(4rem, 12vw, 6.5rem); color: var(--white); margin-bottom: 1.2rem; text-shadow: 0 4px 20px rgba(0,0,0,0.3); animation: fadeUp 1s ease 0.2s both; }
.header-subtitle { 
  font-family: var(--ff-body);
  font-size: 1.5rem; 
  font-weight: 400;
  color: var(--gold-light);

  font-style: italic; 
  margin-bottom: 3rem; 
  animation: fadeUp 1s ease 0.4s both;
}
.header-divider { display: flex; align-items: center; gap: 1rem; max-width: 420px; margin: 0 auto; animation: fadeUp 1s ease 0.6s both; }
.divider-line { flex: 1; height: 1px; background: var(--gold-grad); opacity: 0.6; }
.divider-diamond { color: var(--gold); font-size: 0.6rem; }

/* ===================== MODE TOGGLE (RESTORED OLD BUTTONS) ===================== */
.mode-toggle {
  display: flex; justify-content: center; gap: 20px; margin-bottom: 50px; margin-top: -30px; position: relative; z-index: 10;
}

.mode-btn {
  padding: 14px 35px; border-radius: 40px; border: 1px solid var(--gold);
  background: rgba(255,255,255,0.1); backdrop-filter: blur(10px); color: var(--white); font-family: var(--ff-ui); font-weight: 600;
  cursor: pointer; transition: all 0.4s ease; box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.mode-btn:hover { background: rgba(255,255,255,0.2); }
.mode-btn.active { background: var(--warm-brown); color: white; border-color: var(--warm-brown); }

/* ===================== SLIDE TOGGLES ===================== */
.slide-toggle-container {
  position: relative;
  display: inline-flex;
  background: rgba(223, 191, 159, 0.15);
  padding: 5px;
  border-radius: 50px;
  border: 1px solid var(--ivory-dark);
  margin-left: 3.45rem;
  margin-bottom: 2rem;
  overflow: hidden;
}

.slide-toggle-item {
  position: relative;
  z-index: 2;
  padding: 10px 25px;
  font-family: var(--ff-ui);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.3s ease;
  white-space: nowrap;
}

.slide-toggle-item.active {
  color: white;
}

.slide-active-bg {
  position: absolute;
  top: 5px;
  left: 5px;
  height: calc(100% - 10px);
  background: var(--warm-brown);
  border-radius: 40px;
  transition: all 0.4s cubic-bezier(0.19, 1, 0.22, 1);
  z-index: 1;
  box-shadow: 0 4px 10px rgba(74, 59, 42, 0.2);
}

/* ===================== PLANNER (RICH RESTORATION) ===================== */
.main-container { max-width: 1100px; margin: 0 auto; padding: 3rem 1.5rem 5rem; }
.step-section { margin-bottom: 4rem; }
.step-label { display: flex; align-items: center; gap: 1.25rem; margin-bottom: 0.6rem; }
.step-number {
  font-family: var(--ff-serif); font-size: 0.85rem; color: var(--gold);
  border: 1px solid var(--gold); border-radius: 50%; width: 2.2rem; height: 2.2rem;
  display: flex; align-items: center; justify-content: center;
}
.step-title { font-family: var(--ff-serif); font-size: 1.65rem; font-weight: 600; color: var(--warm-brown); }
.step-desc { font-size: 0.95rem; color: var(--text-muted); margin-bottom: 1.5rem; padding-left: 3.45rem; }

/* Tabs & Grid */
.tab-bar { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 2rem; padding-left: 3.45rem; }
.tab-btn {
  font-family: var(--ff-ui); font-size: 0.8rem; padding: 0.5rem 1.2rem;
  border: 1px solid var(--ivory-dark); border-radius: 100px; background: white; color: var(--text-muted); cursor: pointer;
}
.tab-btn.active { background: var(--warm-brown); color: white; }

.places-grid { 
  display: grid; 
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); 
  gap: 1.8rem; 
}

.place-card { 
  background: white; 
  border-radius: 24px; 
  overflow: hidden; 
  border: 1px solid var(--ivory-dark); 
  cursor: pointer; 
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  box-shadow: 0 4px 15px rgba(0,0,0,0.03);
  display: flex;
  flex-direction: column;
  position: relative;
}

.place-card:hover { 
  transform: translateY(-8px); 
  border-color: var(--gold); 
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.1), 0 0 0 1px var(--gold-light);
}

.place-card.selected { 
  border-color: var(--gold); 
  background: white;
  box-shadow: 0 0 0 2px var(--gold), 0 10px 30px rgba(197, 160, 89, 0.15);
}

.card-img-box { 
  width: 100%; 
  height: 180px; 
  overflow: hidden; 
  background: #f9f7f5;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card-img-box img { 
  width: 100%; 
  height: 100%; 
  object-fit: cover; 
  transition: transform 0.5s ease;
}

.place-card:hover .card-img-box img {
  transform: scale(1.08);
}

.card-info { padding: 1.8rem; flex: 1; display: flex; flex-direction: column; }
.card-cat { 
  font-family: var(--ff-ui); 
  font-size: 0.7rem; 
  color: var(--gold); 
  text-transform: uppercase; 
  letter-spacing: 0.1em;
  font-weight: 700;
  margin-bottom: 8px; 
}

.card-name { 
  font-family: var(--ff-serif); 
  font-size: 1.3rem; 
  font-weight: 700; 
  color: var(--warm-brown);
  line-height: 1.2;
  margin-bottom: 10px;
}

.card-desc {
  font-family: var(--ff-body);
  font-size: 0.95rem;
  color: var(--text-main);
  line-height: 1.5;
  margin-bottom: 15px;
  opacity: 0.8;
}

.card-meta {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--ff-ui);
  font-size: 0.75rem;
  color: var(--text-muted);
}

.card-check-badge {
  position: absolute;
  top: 15px;
  right: 15px;
  width: 30px;
  height: 30px;
  background: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  color: transparent;
  transition: all 0.3s ease;
  z-index: 5;
}

.place-card.selected .card-check-badge {
  background: var(--gold);
  color: white;
}

/* Conditions */
.option-chips { display: flex; gap: 0.75rem; flex-wrap: wrap; padding-left: 3.45rem; }
.chip-content { display: inline-block; padding: 0.7rem 1.5rem; background: white; border: 1px solid var(--ivory-dark); border-radius: 100px; font-family: var(--ff-ui); font-size: 0.9rem; }
.chip input:checked + .chip-content { background: var(--warm-brown); color: white; }

/* ===================== RESULT TIMELINE (PREMIUM) ===================== */
.day-block { 
  margin-bottom: 4.5rem; 
  animation: fadeUp 0.6s ease both;
}

.day-header { 
  display: flex; 
  align-items: baseline; 
  gap: 1.2rem; 
  margin-bottom: 2.5rem; 
  border-bottom: 1px solid var(--gold); 
  padding-bottom: 15px;
  position: relative;
}

.day-header::after {
  content: '◆';
  position: absolute;
  bottom: -9px;
  left: 50%;
  transform: translateX(-50%);
  color: var(--gold);
  font-size: 0.8rem;
  background: var(--cream);
  padding: 0 10px;
}

.day-badge { 
  background: var(--midnight-blue); 
  color: var(--gold-light); 
  padding: 0.5rem 1.4rem; 
  border-radius: 100px; 
  font-family: var(--ff-ui);
  font-size: 0.85rem; 
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border: 1px solid var(--gold);
}

.day-theme {
  font-family: var(--ff-serif);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--midnight-blue);
  font-style: italic;
}

.schedule-list {
  position: relative;
  padding-left: 2rem;
}

.schedule-list::before {
  content: '';
  position: absolute;
  top: 0; left: 0; bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, transparent, var(--gold) 10%, var(--gold) 90%, transparent);
}

.schedule-item { 
  background: white; 
  border: 1px solid var(--ivory-dark); 
  border-radius: 24px; 
  padding: 2.5rem; 
  margin-bottom: 2rem; 
  display: flex; 
  gap: 2.5rem;
  transition: all 0.4s ease;
  box-shadow: 0 4px 20px rgba(0,0,0,0.02);
  position: relative;
}

.schedule-item::before {
  content: '◆';
  position: absolute;
  left: -2rem; /* Matches padding-left of schedule-list */
  top: 3rem;
  transform: translateX(-50%);
  color: var(--gold);
  font-size: 0.8rem;
  background: var(--cream);
  padding: 4px 0;
}

.schedule-item:hover {
  transform: translateX(10px) translateY(-5px);
  box-shadow: 0 15px 40px rgba(15, 23, 42, 0.08);
  border-color: var(--gold-light);
}

.schedule-time { 
  font-family: var(--ff-ui); 
  font-weight: 800; 
  color: var(--gold); 
  font-size: 1.1rem;
  min-width: 80px; 
  padding-top: 5px;
}

.schedule-body { flex: 1; }

.schedule-name { 
  font-family: var(--ff-serif); 
  font-size: 1.4rem; 
  font-weight: 800; /* BOLD as requested */
  color: var(--deep-brown); 
  margin-bottom: 10px;
  letter-spacing: -0.02em;
}

.schedule-menu-box {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(197, 160, 89, 0.08);
  padding: 6px 15px;
  border-radius: 12px;
  margin-bottom: 15px;
  border: 1px dashed var(--gold);
}

.menu-label {
  font-family: var(--ff-ui);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--gold);
  text-transform: uppercase;
}

.menu-value {
  font-family: var(--ff-body);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--warm-brown);
  font-style: italic;
}

.schedule-tip {
  font-family: var(--ff-body);
  font-size: 1.05rem;
  color: var(--text-main);
  line-height: 1.7;
  opacity: 0.9;
}

.schedule-cat-badge {
  display: inline-block;
  font-family: var(--ff-ui);
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 3px 10px;
  border-radius: 6px;
  background: var(--ivory-dark);
  color: var(--gold);
  margin-bottom: 12px;
}

.golden-hour-alert {
  display: flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, #fff9e6 0%, #fff0cc 100%);
  border: 1px solid #ffd966;
  padding: 10px 15px;
  border-radius: 12px;
  margin-bottom: 15px;
  font-family: var(--ff-body);
  font-size: 0.95rem;
  color: #856404;
  font-style: italic;
  animation: gentle-glow 2s infinite ease-in-out;
}

@keyframes gentle-glow {
  0%, 100% { box-shadow: 0 0 5px rgba(255, 217, 102, 0.2); }
  50% { box-shadow: 0 0 15px rgba(255, 217, 102, 0.5); }
}

.expense-tag {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 15px;
  padding-top: 15px;
  border-top: 1px solid var(--ivory-dark);
  font-family: var(--ff-ui);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
}

.expense-value {
  color: var(--warm-brown);
  font-size: 1rem;
}

.day-footer-expense {
  background: #fdfcfb;
  border: 2px dashed var(--gold-light);
  border-radius: 20px;
  padding: 1.5rem 2.5rem;
  margin-top: -1rem;
  margin-bottom: 3rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.day-total-label {
  font-family: var(--ff-serif);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--deep-brown);
}

.day-total-value {
  font-family: var(--ff-serif);
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--gold);
}
.cta-btn {
  background: var(--warm-brown); color: white; padding: 1.2rem 3.5rem; border-radius: 16px; border: 1px solid var(--gold);
  font-family: var(--ff-serif); font-size: 1.1rem; cursor: pointer; transition: all 0.3s ease; box-shadow: 0 10px 25px rgba(74, 59, 42, 0.2);
}
.cta-btn:hover { transform: translateY(-3px); box-shadow: 0 15px 35px rgba(74, 59, 42, 0.3); }

/* ===================== CHAT (MESSENGER UI KEPT) ===================== */
#chat-view {
  background: white; border-radius: 32px; box-shadow: var(--shadow-md); height: 700px; display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--ivory-dark);
}
.chat-header { padding: 24px 40px; background: #fdfcfb; border-bottom: 1px solid var(--ivory-dark); display: flex; align-items: center; gap: 15px; }
#chat-history { flex: 1; padding: 40px; overflow-y: auto; display: flex; flex-direction: column; gap: 24px; background: #faf9f7; }
.message { max-width: 75%; padding: 16px 24px; font-family: var(--ff-ui); font-size: 1rem; line-height: 1.6; }
.message.user { align-self: flex-end; background: var(--warm-brown); color: white; border-radius: 24px 24px 4px 24px; }
.message.bot { align-self: flex-start; background: white; color: var(--text-main); border-radius: 24px 24px 24px 4px; border: 1px solid var(--ivory-dark); }
.chat-input-area { padding: 30px 40px; background: white; border-top: 1px solid var(--ivory-dark); display: flex; gap: 15px; }
#chat-input { flex: 1; background: #f5f3f0; border: 1px solid var(--ivory-dark); padding: 18px 25px; border-radius: 18px; font-family: var(--ff-ui); font-size: 1rem; }
.send-btn { width: 55px; height: 55px; background: var(--warm-brown); color: white; border: none; border-radius: 15px; cursor: pointer; }

/* Loading & Utils */
.loading-overlay { position: fixed; inset: 0; background: rgba(253, 250, 245, 0.9); backdrop-filter: blur(8px); z-index: 2000; display: flex; align-items: center; justify-content: center; }
.loading-card { background: white; padding: 3rem; border-radius: 24px; text-align: center; box-shadow: var(--shadow-md); }
.typing-indicator { display: flex; gap: 6px; }
.typing-dot { width: 6px; height: 6px; background: var(--gold); border-radius: 50%; animation: typing 1.4s infinite ease-in-out; }
@keyframes typing { 0%, 80%, 100% { transform: scale(0); opacity: 0.3; } 40% { transform: scale(1); opacity: 1; } }

/* ===================== FLIGHT TICKET (BOARDING PASS) UI ===================== */
.ticket-wrapper {
  display: flex;
  justify-content: center;
  margin: 3rem 0 5rem;
  animation: slideInUp 0.8s cubic-bezier(0.165, 0.84, 0.44, 1) both;
  perspective: 1000px;
}

.flight-ticket {
  display: flex;
  width: 100%;
  max-width: 950px;
  background: white;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.15);
  position: relative;
  border: 1px solid var(--ivory-dark);
}

.ticket-left {
  flex: 1;
  padding: 1.5rem 2rem;
  position: relative;
  border-right: 2px dashed var(--ivory-dark);
}

/* Semi-circles for the tear line */
.ticket-left::after, .ticket-left::before {
  content: '';
  position: absolute;
  right: -15px;
  width: 30px;
  height: 30px;
  background: var(--cream);
  border-radius: 50%;
  border: 1px solid var(--ivory-dark);
  z-index: 10;
}
.ticket-left::before { top: -15px; border-bottom: none; }
.ticket-left::after { bottom: -15px; border-top: none; }

.ticket-right {
  width: 250px;
  background: var(--midnight-blue);
  color: white;
  padding: 1.5rem 2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
}

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

.airline-logo {
  font-family: var(--ff-serif);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--midnight-blue);
  display: flex;
  align-items: center;
  gap: 8px;
}

.airline-logo span { color: var(--gold); }

.flight-route {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 1.2rem;
}

.route-code {
  font-family: var(--ff-ui);
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--midnight-blue);
  line-height: 1;
}

.route-plane {
  color: var(--gold);
  font-size: 1.3rem;
}

.route-city {
  font-family: var(--ff-ui);
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-top: 2px;
}

.ticket-details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

.detail-group label {
  display: block;
  font-family: var(--ff-ui);
  font-size: 0.65rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 2px;
}

.detail-group p {
  font-family: var(--ff-serif);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--warm-brown);
  line-height: 1.2;
}

.ticket-theme {
  background: rgba(197, 160, 89, 0.08);
  padding: 0.8rem 1.2rem;
  border-radius: 10px;
  border-left: 3px solid var(--gold);
}

.ticket-right .detail-group label {
  color: rgba(255, 255, 255, 0.6);
}

.ticket-right .detail-group p {
  color: var(--gold-light);
}

.barcode-area {
  margin-top: auto;
  text-align: center;
}

.barcode-lines {
  height: 40px;
  background: repeating-linear-gradient(
    to right,
    var(--white) 0,
    var(--white) 2px,
    transparent 2px,
    transparent 4px,
    var(--white) 4px,
    var(--white) 7px,
    transparent 7px,
    transparent 10px
  );
  opacity: 0.5;
  margin-bottom: 10px;
}

.barcode-text {
  font-family: monospace;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 0.3em;
}

@keyframes slideInUp {
  0% { transform: translateY(50px) rotateX(-10deg); opacity: 0; }
  100% { transform: translateY(0) rotateX(0); opacity: 1; }
}
