:root {
  --bg-primary: #0a0e1a;
  --bg-secondary: #12182b;
  --bg-card: #1a2238;
  --bg-card-hover: #222d4a;
  --border: rgba(255,255,255,0.08);
  --border-active: rgba(255,255,255,0.15);
  --text-primary: #f0f2f5;
  --text-secondary: #8b92a8;
  --text-muted: #5a6078;
  --accent: #e8b84a;
  --accent-light: #f5d78e;
  --accent-glow: rgba(232, 184, 74, 0.3);
  --success: #4ade80;
  --danger: #f87171;
  --info: #60a5fa;
  --warning: #fbbf24;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.3);
  --shadow-md: 0 4px 20px rgba(0,0,0,0.4);
  --shadow-lg: 0 8px 40px rgba(0,0,0,0.5);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Inter', 'Noto Sans TC', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Loader */
.loader {
  position: fixed;
  inset: 0;
  background: var(--bg-primary);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.5s, visibility 0.5s;
}
.loader.hidden {
  opacity: 0;
  visibility: hidden;
}
.loader-content {
  text-align: center;
}
.loader-plane {
  font-size: 64px;
  animation: fly 2s ease-in-out infinite;
  margin-bottom: 16px;
}
@keyframes fly {
  0%, 100% { transform: translateY(0) rotate(-5deg); }
  50% { transform: translateY(-15px) rotate(5deg); }
}
.loader-text {
  font-size: 18px;
  color: var(--text-secondary);
  font-weight: 500;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(10, 14, 26, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: all 0.3s;
}
.header.scrolled {
  background: rgba(10, 14, 26, 0.95);
  box-shadow: var(--shadow-sm);
}
.header-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
}
.logo-icon {
  font-size: 28px;
}
.logo-title {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.3px;
}
.logo-subtitle {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: -2px;
}
.header-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}
.btn-icon {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}
.btn-icon:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.btn-lang {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  padding: 8px 14px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
}
.btn-lang:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.lang-current {
  color: var(--accent);
}
.btn-add {
  background: var(--accent);
  border: none;
  color: #1a1508;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 22px;
  font-weight: 300;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  box-shadow: 0 0 20px var(--accent-glow);
}
.btn-add:hover {
  transform: scale(1.1);
  box-shadow: 0 0 30px var(--accent-glow);
}

/* Hero */
.hero {
  position: relative;
  padding: 100px 20px 40px;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(232, 184, 74, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse at 70% 80%, rgba(96, 165, 250, 0.06) 0%, transparent 50%);
  pointer-events: none;
}
.hero-content {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
  position: relative;
  z-index: 1;
}
.hero-title {
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -1px;
  margin-bottom: 8px;
  background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-dates {
  font-size: 16px;
  color: var(--text-secondary);
  font-weight: 500;
  margin-bottom: 24px;
}
.hero-travelers {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 32px;
}
.traveler-avatars {
  display: flex;
}
.avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 2px solid var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  margin-left: -8px;
  transition: transform 0.2s;
}
.avatar:first-child {
  margin-left: 0;
}
.avatar:hover {
  transform: translateY(-4px);
  z-index: 2;
}
.travelers-text {
  font-size: 14px;
  color: var(--text-secondary);
  font-weight: 500;
}
.hero-cities {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}
.city-chip {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 10px 16px;
  border-radius: 30px;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 14px;
  font-weight: 500;
}
.city-chip:hover, .city-chip.active {
  border-color: var(--accent);
  background: rgba(232, 184, 74, 0.1);
}
.city-chip.active .city-name {
  color: var(--accent);
}
.city-days {
  font-size: 11px;
  background: rgba(255,255,255,0.1);
  padding: 2px 6px;
  border-radius: 8px;
  color: var(--text-muted);
}
.city-arrow {
  color: var(--text-muted);
  font-size: 14px;
}

/* Countdown */
.countdown-section {
  max-width: 800px;
  margin: 0 auto 32px;
  padding: 0 20px;
  text-align: center;
}
.countdown-label {
  font-size: 13px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 12px;
}
.countdown {
  display: flex;
  justify-content: center;
  gap: 24px;
}
.countdown-item {
  text-align: center;
}
.countdown-num {
  font-size: 42px;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.countdown-unit {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Main Content */
.main-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 20px;
}

/* City Section */
.city-section {
  margin-bottom: 40px;
}
.city-header {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 20px;
}
.city-header-bg {
  position: absolute;
  inset: 0;
  opacity: 0.9;
}
.city-header-content {
  position: relative;
  padding: 28px 24px;
  z-index: 1;
}
.city-flag {
  font-size: 32px;
  margin-bottom: 8px;
}
.city-title {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 6px;
  letter-spacing: -0.5px;
}
.city-desc {
  font-size: 14px;
  color: rgba(255,255,255,0.75);
  line-height: 1.5;
  margin-bottom: 8px;
  max-width: 90%;
}
.city-dates {
  font-size: 14px;
  color: rgba(255,255,255,0.7);
  margin-bottom: 16px;
}
.city-weather {
  background: rgba(0,0,0,0.25);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  backdrop-filter: blur(10px);
}
.weather-loading {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: rgba(255,255,255,0.6);
}
.weather-spinner {
  animation: spin 2s linear infinite;
}
@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
.weather-loaded {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.weather-main {
  display: flex;
  align-items: center;
  gap: 8px;
}
.weather-icon {
  font-size: 28px;
}
.weather-temp {
  font-size: 24px;
  font-weight: 700;
}
.weather-desc {
  font-size: 13px;
  color: rgba(255,255,255,0.7);
}
.weather-forecast {
  display: flex;
  gap: 12px;
  flex: 1;
  justify-content: flex-end;
}
.weather-day {
  text-align: center;
  background: rgba(255,255,255,0.1);
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  min-width: 50px;
}
.weather-day-name {
  font-size: 10px;
  color: rgba(255,255,255,0.6);
  text-transform: uppercase;
}
.weather-day-icon {
  font-size: 18px;
  margin: 2px 0;
}
.weather-day-temp {
  font-size: 12px;
  font-weight: 600;
}

.weather-day-temp {
  font-size: 12px;
  font-weight: 600;
}

.weather-error {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--text-muted);
  flex-wrap: wrap;
}
.weather-retry {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--accent);
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 12px;
  cursor: pointer;
  margin-left: auto;
}
.weather-retry:hover {
  border-color: var(--accent);
}

/* Maps */
.city-map {
  height: 260px;
  border-radius: var(--radius-md);
  margin-top: 16px;
  overflow: hidden;
  border: 1px solid var(--border);
}

/* Leaflet dark theme overrides */
.leaflet-container {
  background: var(--bg-secondary);
  font-family: 'Inter', 'Noto Sans TC', sans-serif;
}
.leaflet-popup-content-wrapper {
  background: var(--bg-card);
  color: var(--text-primary);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
}
.leaflet-popup-tip {
  background: var(--bg-card);
  border: 1px solid var(--border);
}
.leaflet-popup-content {
  margin: 0;
}
.map-popup {
  padding: 8px 4px;
  min-width: 160px;
}
.map-popup-title {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 4px;
}
.map-popup-time {
  font-size: 12px;
  color: var(--text-secondary);
}
.map-popup-booking {
  font-size: 11px;
  color: var(--accent);
  margin-top: 4px;
}

/* Timeline */
.timeline {
  position: relative;
  padding-left: 28px;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 8px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent) 0%, var(--border) 100%);
  border-radius: 2px;
}

/* Timeline Item */
.timeline-item {
  position: relative;
  margin-bottom: 16px;
  animation: slideIn 0.4s ease-out;
}
@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(-10px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}
.timeline-dot {
  position: absolute;
  left: -24px;
  top: 16px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 2px solid var(--accent);
  z-index: 1;
}
.timeline-dot.flight {
  border-color: var(--info);
  background: var(--info);
}
.timeline-dot.meal {
  border-color: #f472b6;
}
.timeline-dot.transport {
  border-color: var(--warning);
}
.timeline-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px;
  transition: all 0.2s;
}
.timeline-card:hover {
  border-color: var(--border-active);
  background: var(--bg-card-hover);
}
.timeline-card.user-added {
  border-left: 3px solid var(--accent);
}
.timeline-time {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  background: rgba(232, 184, 74, 0.1);
  padding: 4px 10px;
  border-radius: 12px;
  margin-bottom: 8px;
}
.timeline-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 6px;
  line-height: 1.4;
}
.timeline-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
}
.timeline-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
  align-items: center;
}
.timeline-booking {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--success);
  background: rgba(74, 222, 128, 0.1);
  padding: 4px 10px;
  border-radius: 8px;
}
.map-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--info);
  background: rgba(96, 165, 250, 0.1);
  padding: 4px 10px;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.2s;
}
.map-link:hover {
  background: rgba(96, 165, 250, 0.2);
}

.participants-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--accent);
  background: rgba(232, 184, 74, 0.1);
  padding: 4px 10px;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.2s;
  cursor: pointer;
  border: none;
}
.participants-link:hover {
  background: rgba(232, 184, 74, 0.2);
}

.participants-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.participant-item {
  padding: 10px 14px;
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  margin-bottom: 6px;
  font-size: 14px;
  color: var(--text-primary);
  border: 1px solid var(--border);
  transition: all 0.2s;
}
.participant-item:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-active);
}

.timeline-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}
.timeline-actions button {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s;
}
.timeline-actions button:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.timeline-date-header {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin: 24px 0 12px -28px;
  padding-left: 28px;
}

/* Tools Panel */
.tools-panel {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  max-width: 420px;
  background: var(--bg-secondary);
  border-left: 1px solid var(--border);
  z-index: 150;
  transform: translateX(100%);
  transition: transform 0.3s ease-out;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}
.tools-panel.active {
  transform: translateX(0);
}
.tools-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: var(--bg-secondary);
  z-index: 1;
}
.tools-header h3 {
  font-size: 18px;
  font-weight: 700;
}
.tools-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 24px;
  cursor: pointer;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.2s;
}
.tools-close:hover {
  background: var(--bg-card);
  color: var(--text-primary);
}
.tools-body {
  padding: 20px 24px 40px;
  flex: 1;
}
.tool-section {
  margin-bottom: 32px;
}
.tool-section h4 {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 14px;
  color: var(--text-primary);
}

/* Currency Converter */
.currency-converter {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px;
}
.currency-row {
  display: flex;
  align-items: center;
  gap: 12px;
}
.currency-row input {
  flex: 1;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  color: var(--text-primary);
  font-size: 16px;
  font-weight: 600;
  font-family: inherit;
}
.currency-row input:focus {
  outline: none;
  border-color: var(--accent);
}
.currency-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  min-width: 70px;
  text-align: right;
}
.currency-equals {
  text-align: center;
  font-size: 20px;
  color: var(--text-muted);
  margin: 8px 0;
}
.currency-rate {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 10px;
  text-align: center;
}

/* Packing Checklist */
.checklist {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.checklist-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s;
  font-size: 14px;
}
.checklist-item:hover {
  background: var(--bg-card);
}
.checklist-item.checked {
  opacity: 0.5;
}
.checklist-item.checked .checklist-text {
  text-decoration: line-through;
}
.checklist-item input {
  display: none;
}
.checklist-check {
  font-size: 18px;
  flex-shrink: 0;
}
.checklist-text {
  color: var(--text-primary);
}

/* Emergency */
.emergency-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.emergency-item {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px 14px;
}
.emergency-icon {
  font-size: 24px;
}
.emergency-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 2px;
}
.emergency-num {
  font-size: 16px;
  font-weight: 700;
  color: var(--accent);
  font-family: monospace;
}

/* Timezones */
.timezone-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.timezone-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-size: 14px;
}
.timezone-name {
  color: var(--text-secondary);
}
.timezone-time {
  font-weight: 700;
  color: var(--accent);
  font-family: monospace;
  font-size: 16px;
}

/* Stats */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}
.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px 8px;
  text-align: center;
}
.stat-value {
  font-size: 24px;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
}
.stat-label {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Flights Section */
.flights-section {
  max-width: 800px;
  margin: 40px auto;
  padding: 0 20px;
}
.section-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 20px;
  padding-left: 12px;
  border-left: 3px solid var(--accent);
}
.flights-grid {
  display: grid;
  gap: 12px;
}
.flight-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all 0.2s;
}
.flight-card:hover {
  border-color: var(--border-active);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.flight-card.outbound {
  border-left: 4px solid var(--accent);
}
.flight-card.return {
  border-left: 4px solid var(--info);
}
.flight-card.domestic {
  border-left: 4px solid var(--success);
}
.flight-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: rgba(255,255,255,0.03);
  border-bottom: 1px solid var(--border);
}
.flight-type-badge {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 4px 10px;
  border-radius: 12px;
}
.outbound .flight-type-badge {
  background: rgba(232, 184, 74, 0.15);
  color: var(--accent);
}
.return .flight-type-badge {
  background: rgba(96, 165, 250, 0.15);
  color: var(--info);
}
.domestic .flight-type-badge {
  background: rgba(74, 222, 128, 0.15);
  color: var(--success);
}
.flight-date {
  font-size: 13px;
  color: var(--text-muted);
}
.flight-body {
  padding: 20px 16px;
}
.flight-route-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.flight-airport {
  text-align: center;
  min-width: 80px;
}
.flight-code {
  font-size: 20px;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
}
.flight-city {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}
.flight-time-lg {
  font-size: 24px;
  font-weight: 700;
  color: var(--accent);
  margin-top: 8px;
  line-height: 1;
}
.flight-path {
  flex: 1;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}
.flight-airline-name {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
}
.flight-line {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  max-width: 120px;
}
.flight-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}
.flight-plane {
  font-size: 16px;
  flex-shrink: 0;
}
.flight-duration {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
}
.flight-num {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-primary);
  font-family: monospace;
  background: var(--bg-secondary);
  padding: 3px 10px;
  border-radius: 6px;
}

/* Footer */
.footer {
  border-top: 1px solid var(--border);
  padding: 32px 20px;
  text-align: center;
  margin-top: 40px;
}
.footer-content {
  max-width: 800px;
  margin: 0 auto;
}
.footer p {
  font-size: 13px;
  color: var(--text-muted);
}
.footer-updated {
  margin-top: 8px;
  font-size: 11px !important;
}

/* Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(8px);
  z-index: 200;
  display: none;
  align-items: flex-end;
  justify-content: center;
  padding: 0;
}
.modal-overlay.active {
  display: flex;
}
.modal {
  background: var(--bg-secondary);
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  animation: slideUp 0.3s ease-out;
}
@keyframes slideUp {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: var(--bg-secondary);
  z-index: 1;
}
.modal-header h3 {
  font-size: 18px;
  font-weight: 700;
}
.modal-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 24px;
  cursor: pointer;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.2s;
}
.modal-close:hover {
  background: var(--bg-card);
  color: var(--text-primary);
}
.modal-body {
  padding: 20px 24px 32px;
}
.form-group {
  margin-bottom: 16px;
}
.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  color: var(--text-primary);
  font-size: 15px;
  font-family: inherit;
  transition: all 0.2s;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}
.form-group textarea {
  resize: vertical;
  min-height: 80px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.form-actions {
  display: flex;
  gap: 12px;
  margin-top: 24px;
}
.btn-primary {
  flex: 1;
  background: var(--accent);
  border: none;
  color: #1a1508;
  padding: 14px 24px;
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px var(--accent-glow);
}
.btn-secondary {
  flex: 1;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  padding: 14px 24px;
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-secondary:hover {
  border-color: var(--text-secondary);
  color: var(--text-primary);
}

/* Toast */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 14px 24px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 500;
  z-index: 300;
  opacity: 0;
  transition: all 0.3s;
  pointer-events: none;
  white-space: nowrap;
}
.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
.toast.success {
  border-color: var(--success);
  color: var(--success);
}
.toast.error {
  border-color: var(--danger);
  color: var(--danger);
}

/* Responsive */
@media (min-width: 640px) {
  .hero {
    padding: 120px 20px 60px;
  }
  .hero-title {
    font-size: 48px;
  }
  .countdown-num {
    font-size: 56px;
  }
  .city-title {
    font-size: 32px;
  }
  .modal {
    border-radius: var(--radius-xl);
    margin: 40px auto;
    max-height: calc(100vh - 80px);
  }
  .modal-overlay {
    align-items: center;
    padding: 20px;
  }
}

@media (max-width: 480px) {
  .hero-cities {
    gap: 6px;
  }
  .city-chip {
    padding: 8px 12px;
    font-size: 12px;
  }
  .countdown {
    gap: 16px;
  }
  .countdown-num {
    font-size: 36px;
  }
  .weather-forecast {
    justify-content: flex-start;
    margin-top: 12px;
    width: 100%;
  }
  .form-row {
    grid-template-columns: 1fr;
  }
  .flight-card {
    border-radius: var(--radius-md);
  }
  .flight-route-row {
    gap: 8px;
  }
  .flight-code {
    font-size: 16px;
  }
  .flight-time-lg {
    font-size: 20px;
  }
  .flight-city {
    font-size: 11px;
  }
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .tools-panel {
    max-width: 100%;
  }
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
  background: var(--border-active);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}