body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  margin: 0;
  padding: 0;
  text-align: center;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  min-height: 100vh;
  position: relative;
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><defs><radialGradient id="a" cx="50%" cy="50%"><stop offset="0%" style="stop-color:%23ffffff;stop-opacity:0.1"/><stop offset="100%" style="stop-color:%23ffffff;stop-opacity:0"/></radialGradient></defs><rect width="100%" height="100%" fill="url(%23a)"/></svg>') center/cover;
  z-index: -1;
}

.header {
  padding: 25px 20px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  color: #2c3e50;
  margin-bottom: 30px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  border-bottom: 3px solid #e67e22;
}

.header h1 {
  margin: 0;
  font-size: 3rem;
  font-weight: 700;
  background: linear-gradient(135deg, #e67e22, #d35400);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.subtitle {
  margin: 15px 0 0 0;
  font-size: 1.2rem;
  color: #7f8c8d;
  font-weight: 500;
}

/* GPT Travel Assistant Section */
.gpt-section {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(15px);
  color: #2c3e50;
  padding: 40px 30px;
  margin: 30px auto;
  border-radius: 20px;
  max-width: 900px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  position: relative;
  overflow: hidden;
}

.gpt-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, #e67e22, #f39c12, #e74c3c);
}

.gpt-section h2 {
  margin: 0 0 15px 0;
  font-size: 2.2rem;
  font-weight: 700;
  background: linear-gradient(135deg, #e67e22, #d35400);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.gpt-subtitle {
  margin: 0 0 25px 0;
  font-size: 1.1rem;
  color: #7f8c8d;
  font-weight: 500;
}

.gpt-form {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin: 0;
  flex-wrap: wrap;
}

.gpt-form input {
  padding: 18px 25px;
  border: 2px solid rgba(230, 126, 34, 0.2);
  border-radius: 50px;
  font-size: 16px;
  min-width: 400px;
  max-width: 500px;
  flex: 1;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
  color: #2c3e50;
  font-weight: 500;
}

.gpt-form input:focus {
  outline: none;
  border-color: #e67e22;
  box-shadow: 0 8px 30px rgba(230, 126, 34, 0.3);
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 1);
}

.gpt-form input::placeholder {
  color: #95a5a6;
  font-weight: 400;
}

.gpt-form button {
  padding: 18px 30px;
  background: linear-gradient(135deg, #e67e22, #d35400);
  color: white;
  border: none;
  border-radius: 50px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  transition: all 0.3s ease;
  white-space: nowrap;
  box-shadow: 0 8px 25px rgba(230, 126, 34, 0.3);
  position: relative;
  overflow: hidden;
}

.gpt-form button::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s;
}

.gpt-form button:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(230, 126, 34, 0.4);
  background: linear-gradient(135deg, #f39c12, #e67e22);
}

.gpt-form button:hover::before {
  left: 100%;
}

.gpt-form button:active {
  transform: translateY(-1px);
}

.gpt-result {
  margin-top: 25px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(15px);
  padding: 25px;
  border-radius: 15px;
  border: 1px solid rgba(230, 126, 34, 0.2);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.gpt-result p {
  margin: 8px 0;
  font-size: 15px;
  color: #2c3e50;
  line-height: 1.6;
}

.error-message {
  margin-top: 25px;
  background: rgba(231, 76, 60, 0.1);
  backdrop-filter: blur(15px);
  color: #e74c3c;
  padding: 20px;
  border-radius: 15px;
  border: 1px solid rgba(231, 76, 60, 0.3);
  font-weight: 600;
}

/* Enhanced place item styles */
.place-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
  border-color: rgba(230, 126, 34, 0.4);
}

.place-item input[type="checkbox"]:checked + .place-info {
  color: #2c3e50;
}

.place-item input[type="checkbox"]:checked {
  accent-color: #e67e22;
}

.place-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, #e67e22, #f39c12);
  border-radius: 15px 15px 0 0;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.place-item:hover::before {
  opacity: 1;
}

/* Build itinerary button enhancements */
.build-itinerary-btn:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 15px 40px rgba(230, 126, 34, 0.4);
}

.build-itinerary-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s;
}

.build-itinerary-btn:hover::before {
  left: 100%;
}

.error-message p {
  margin: 0;
  font-weight: bold;
}

/* Divider */
.divider {
  margin: 30px 0;
  position: relative;
  text-align: center;
}

.divider:before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: #ddd;
}

.divider span {
  background: #f8f9fa;
  padding: 0 20px;
  color: #666;
  font-weight: bold;
}

/* Manual Search Section */
.manual-section {
  margin: 20px;
}

.manual-section h3 {
  color: #333;
  margin-bottom: 15px;
}

.search-form {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin: 20px;
  flex-wrap: wrap;
}

.search-form input {
  padding: 12px 16px;
  border: 2px solid #ddd;
  border-radius: 8px;
  font-size: 16px;
  min-width: 200px;
  transition: border-color 0.3s;
}

.search-form input:focus {
  outline: none;
  border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.search-form button {
  padding: 12px 24px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  transition: transform 0.2s;
}

.search-form button:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.legend {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin: 20px 0;
  flex-wrap: wrap;
}

.legend-item {
  background: white;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 0.9rem;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

#map {
  height: 70vh;
  width: 100%;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Itinerary Section Styles */
.itinerary-section {
  margin: 20px auto;
  max-width: 800px;
  padding: 20px;
  background: white;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.itinerary-section h3 {
  color: #2c3e50;
  margin-bottom: 20px;
  font-size: 1.3rem;
}

.places-list {
  max-height: 400px;
  overflow-y: auto;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 10px;
  margin-bottom: 20px;
}

.place-item {
  display: flex;
  align-items: flex-start;
  padding: 12px;
  border-bottom: 1px solid #f0f0f0;
  cursor: pointer;
  transition: background-color 0.2s;
}

.place-item:hover {
  background-color: #f8f9fa;
}

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

.place-item input[type="checkbox"] {
  margin-right: 12px;
  margin-top: 2px;
  transform: scale(1.2);
}

.place-info {
  flex: 1;
}

.place-info strong {
  color: #2c3e50;
  font-size: 1.1rem;
  display: block;
  margin-bottom: 4px;
}

.rating {
  color: #e67e22;
  font-size: 0.9rem;
  margin-left: 8px;
}

.address {
  color: #666;
  font-size: 0.9rem;
  margin-top: 4px;
}

.price {
  color: #27ae60;
  font-weight: bold;
  font-size: 0.9rem;
  margin-top: 4px;
}

.build-itinerary-btn {
  background: linear-gradient(135deg, #e67e22, #d35400);
  color: white;
  border: none;
  padding: 12px 30px;
  border-radius: 25px;
  font-size: 1.1rem;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  display: block;
  margin: 0 auto;
}

.build-itinerary-btn:hover {
  background: linear-gradient(135deg, #d35400, #c0392b);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(230, 126, 34, 0.3);
}

/* Time-Based Planning Styles */
.time-based-plan {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #667eea 100%);
  color: white;
  border-radius: 15px;
  padding: 25px;
  margin-top: 20px;
  box-shadow: 0 15px 35px rgba(102, 126, 234, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.time-based-plan h3 {
  margin-top: 0;
  font-size: 1.8rem;
  text-align: center;
  color: #ffffff !important;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.time-slots {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.time-slot {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.1));
  border-radius: 12px;
  padding: 20px;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: white;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.time-slot.morning {
  border-left: 4px solid #ffd700; /* Golden yellow for morning */
}

.time-slot.afternoon {
  border-left: 4px solid #ff6b6b; /* Coral for afternoon */  
}

.time-slot.evening {
  border-left: 4px solid #4ecdc4; /* Teal for evening */
}

.time-slot:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
}

.time-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
  padding-bottom: 10px;
  border-bottom: 2px solid rgba(255, 255, 255, 0.4);
}

.time-header h4 {
  margin: 0;
  font-size: 1.3rem;
  color: #ffffff !important;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.time-header h4 small {
  background: rgba(0, 0, 0, 0.2);
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: normal;
  margin-left: 12px;
  display: inline-block;
  color: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(5px);
}

.time-range {
  background: rgba(255, 255, 255, 0.2);
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: bold;
}

.time-places {
  list-style: none;
  padding: 0;
  margin: 0;
}

.time-places li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.time-places li strong {
  color: #ffffff !important;
  font-weight: bold;
  flex: 1;
  margin: 0 10px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
  font-size: 1rem;
}

.time-places li:last-child {
  border-bottom: none;
}

.place-number-small {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 0.8rem;
  margin-right: 10px;
  flex-shrink: 0;
  border: 2px solid rgba(255, 255, 255, 0.6);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
}

.place-rating {
  font-size: 0.8rem;
  opacity: 0.9;
  flex-shrink: 0;
  color: #ffffff;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .time-slots {
    grid-template-columns: 1fr;
  }
  
  .time-header {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }
  
  .time-places li {
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
  }
}

/* Phase 4.4-4.7 - Enhanced Features Styling */

/* Export and Action Controls */
.action-controls {
  transition: all 0.3s ease;
}

.export-btn {
  transition: all 0.3s ease;
  font-weight: 500;
}

.export-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.export-btn:active {
  transform: translateY(0);
}

/* Saved Trips Section */
.saved-trips-section {
  border: 1px solid #e1e8ed;
  transition: all 0.3s ease;
}

.saved-trip-card {
  transition: all 0.3s ease;
}

.saved-trip-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* Easter Eggs Animation */
@keyframes sparkle {
  0% { transform: scale(1) rotate(0deg); }
  50% { transform: scale(1.1) rotate(180deg); }
  100% { transform: scale(1) rotate(360deg); }
}

.easter-egg {
  animation: sparkle 2s infinite ease-in-out;
}

/* Enhanced Place Cards with Easter Eggs */
.place-card {
  overflow: visible;
}

/* Responsive Export Buttons */
@media (max-width: 768px) {
  .action-buttons {
    flex-direction: column;
    align-items: center;
  }
  
  .export-btn {
    width: 200px;
    justify-content: center;
  }
}

.header h1 {
  margin: 0;
  font-size: 3rem;
  font-weight: 700;
  background: linear-gradient(135deg, #e67e22, #d35400);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.export-btn.loading::after {
  content: "...";
  animation: dots 1s infinite;
}

@keyframes dots {
  0%, 20% { content: ""; }
  40% { content: "."; }
  60% { content: ".."; }
  80%, 100% { content: "..."; }
}

/* Enhanced Feedback Messages */
#action-feedback {
  transition: all 0.3s ease;
  padding: 8px 12px;
  border-radius: 5px;
  font-size: 0.9rem;
}

/* High Rating Place Highlight */
.place-card.high-rating {
  background: linear-gradient(135deg, #fff3cd, #ffeaa7);
  border-left-color: #fdcb6e;
}

/* Success States */
.success-message {
  background-color: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
  padding: 10px;
  border-radius: 5px;
  margin: 10px 0;
}

.error-message {
  background-color: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
  padding: 10px;
  border-radius: 5px;
  margin: 10px 0;
}

/* Loading Spinner */
.loading-spinner {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid #f3f3f3;
  border-top: 2px solid #3498db;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-right: 8px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
