/* Reset and base styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary-color: #2563eb;
  --secondary-color: #1e40af;
  --accent-color: #3b82f6;
  --text-color: #1f2937;
  --text-light: #6b7280;
  --bg-color: #ffffff;
  --bg-light: #f9fafb;
  --border-color: #e5e7eb;
  --success-color: #10b981;
  --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  color: var(--text-color);
  background-color: var(--bg-color);
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
header {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  color: white;
  padding: 1rem 0;
  box-shadow: var(--shadow-lg);
  position: sticky;
  top: 0;
  z-index: 1000;
}

header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.logo h1 {
  font-size: 2rem;
  margin-bottom: 0.25rem;
}

.tagline {
  font-size: 0.9rem;
  opacity: 0.9;
}

nav {
  display: flex;
  gap: 1.5rem;
}

nav a {
  color: white;
  text-decoration: none;
  font-weight: 500;
  transition: opacity 0.2s;
}

nav a:hover {
  opacity: 0.8;
}

/* Hero section */
.hero {
  background: linear-gradient(135deg, var(--accent-color), var(--primary-color));
  color: white;
  padding: 4rem 0;
  text-align: center;
}

.hero h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.hero p {
  font-size: 1.25rem;
  opacity: 0.95;
}

/* Features section */
.features {
  padding: 4rem 0;
  background-color: var(--bg-light);
}

.features h2 {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 3rem;
  color: var(--text-color);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.feature-card {
  background: white;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: var(--shadow);
  text-align: center;
  transition: transform 0.2s, box-shadow 0.2s;
}

.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.feature-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.feature-card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

.feature-card p {
  color: var(--text-light);
}

/* Search section */
.search-section {
  padding: 4rem 0;
}

.search-section h2 {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 2rem;
}

.search-box {
  display: flex;
  gap: 1rem;
  margin-bottom: 2rem;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

#searchInput {
  flex: 1;
  padding: 1rem;
  font-size: 1rem;
  border: 2px solid var(--border-color);
  border-radius: 8px;
  transition: border-color 0.2s;
}

#searchInput:focus {
  outline: none;
  border-color: var(--primary-color);
}

button {
  padding: 1rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.2s, transform 0.1s;
}

#searchBtn {
  background-color: var(--primary-color);
  color: white;
}

#searchBtn:hover {
  background-color: var(--secondary-color);
}

#clearBtn {
  background-color: var(--text-light);
  color: white;
}

#clearBtn:hover {
  background-color: var(--text-color);
}

button:active {
  transform: scale(0.98);
}

.search-stats {
  text-align: center;
  margin-bottom: 2rem;
  font-size: 1.1rem;
  color: var(--text-light);
}

.search-results {
  margin-top: 2rem;
}

.region-group {
  margin-bottom: 3rem;
}

.region-group h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--primary-color);
  border-bottom: 2px solid var(--border-color);
  padding-bottom: 0.5rem;
}

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

.airport-card {
  background: white;
  padding: 1.5rem;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  cursor: pointer;
  transition: all 0.2s;
}

.airport-card:hover {
  border-color: var(--primary-color);
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.airport-code {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
}

.airport-name {
  font-weight: 600;
  margin-bottom: 0.25rem;
  color: var(--text-color);
}

.airport-location {
  color: var(--text-light);
  font-size: 0.9rem;
}

/* Map section */
.map-section {
  padding: 4rem 0;
  background-color: var(--bg-light);
}

.map-section h2 {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 1rem;
}

.map-info {
  text-align: center;
  color: var(--text-light);
  margin-bottom: 2rem;
}

.map-container {
  height: 600px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.airport-popup h3 {
  color: var(--primary-color);
  margin-bottom: 0.5rem;
}

.airport-popup p {
  margin-bottom: 0.25rem;
}

/* About section */
.about {
  padding: 4rem 0;
  text-align: center;
}

.about h2 {
  font-size: 2rem;
  margin-bottom: 1.5rem;
}

.about p {
  max-width: 800px;
  margin: 0 auto 3rem;
  color: var(--text-light);
  font-size: 1.1rem;
}

.stats {
  display: flex;
  justify-content: center;
  gap: 4rem;
  flex-wrap: wrap;
}

.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.stat-number {
  font-size: 3rem;
  font-weight: bold;
  color: var(--primary-color);
}

.stat-label {
  font-size: 1rem;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Footer */
footer {
  background-color: var(--text-color);
  color: white;
  padding: 2rem 0;
  text-align: center;
}

footer a {
  color: var(--accent-color);
  text-decoration: none;
}

footer a:hover {
  text-decoration: underline;
}

footer p {
  margin-bottom: 0.5rem;
}

/* Responsive design */
@media (max-width: 768px) {
  header .container {
    flex-direction: column;
    gap: 1rem;
  }
  
  .logo h1 {
    font-size: 1.5rem;
  }
  
  .hero h2 {
    font-size: 1.75rem;
  }
  
  .hero p {
    font-size: 1rem;
  }
  
  .search-box {
    flex-direction: column;
  }
  
  nav {
    width: 100%;
    justify-content: center;
  }
  
  .stats {
    gap: 2rem;
  }
  
  .map-container {
    height: 400px;
  }
}
