/* ==========================================================================
   DESIGN SYSTEM & VARIABLES
   ========================================================================== */
:root {
  /* Color Palette (Inspirada no Jornal PROJUA) */
  --primary-navy: #1e3a8a;      /* Azul Escuro (Prefeitura/Confiança) */
  --primary-navy-hover: #172554;
  --royal-blue: #2563eb;        /* Azul Royal (PROJUA letters) */
  --brand-red: #dc2626;         /* Vermelho (PROJUA 'PRO') */
  --brand-yellow: #eab308;      /* Amarelo/Ouro (Status/Sol) */
  --brand-green: #10b981;       /* Verde (Sucesso/Concluído) */
  
  /* Neutral Colors */
  --bg-main: #f8fafc;
  --bg-card: #ffffff;
  --text-main: #0f172a;
  --text-muted: #475569;
  --border-color: #e2e8f0;
  
  /* Glassmorphism & Shadows */
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --glass-bg: rgba(255, 255, 255, 0.85);
  --glass-border: rgba(255, 255, 255, 0.4);
  
  /* Typography */
  --font-family: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  
  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 30px;
  
  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ==========================================================================
   RESET & BASE STYLES
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-family);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.5;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button, input, select {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

a {
  text-decoration: none;
  color: inherit;
}

/* Hide default scrollbar but keep functionality */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-main);
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* ==========================================================================
   MOBILE FIRST LAYOUT & STYLES (320px - 480px)
   ========================================================================== */

/* Typography Helpers */
.title-xl {
  font-size: clamp(2rem, 6vw, 3rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.title-lg {
  font-size: clamp(1.5rem, 5vw, 2.25rem);
  font-weight: 700;
  line-height: 1.2;
}

.title-md {
  font-size: clamp(1.2rem, 4vw, 1.5rem);
  font-weight: 700;
}

/* Container */
.container {
  width: 100%;
  padding-left: 1.25rem;
  padding-right: 1.25rem;
  margin-left: auto;
  margin-right: auto;
}

/* Header & Navigation */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  padding: 0.75rem 0;
  transition: var(--transition-fast);
}

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

.logo-container {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.logo-prefeitura-img {
  height: 44px;
  width: auto;
  display: block;
}

.logo-divider {
  width: 1px;
  height: 26px;
  background-color: var(--border-color);
}

.logo-projua-img {
  height: 34px;
  width: auto;
  display: block;
}

/* Mobile Nav Toggler */
.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 30px;
  height: 20px;
  background: transparent;
  border: none;
  cursor: pointer;
  z-index: 110;
  padding: 0;
}

.nav-toggle span {
  width: 100%;
  height: 3px;
  background-color: var(--primary-navy);
  border-radius: 2px;
  transition: var(--transition-fast);
}

/* Active Hamburger State */
.nav-toggle.active span:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}
.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}
.nav-toggle.active span:nth-child(3) {
  transform: translateY(-9px) rotate(-45deg);
}

/* Nav Menu */
.nav-menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: 80%;
  max-width: 320px;
  height: 100vh;
  background-color: var(--bg-card);
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
  display: flex;
  flex-direction: column;
  padding: 6rem 2rem 2rem;
  gap: 1.5rem;
  transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 105;
}

.nav-menu.active {
  right: 0;
}

.nav-link {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--primary-navy);
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  transition: var(--transition-fast);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.nav-link:hover, .nav-link.active {
  background-color: rgba(37, 99, 235, 0.08);
  color: var(--royal-blue);
}

.nav-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(15, 23, 42, 0.4);
  backdrop-filter: blur(4px);
  z-index: 102;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.nav-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

/* ==========================================================================
   HERO & STATISTICS SECTION
   ========================================================================== */
.hero {
  padding: 2.5rem 0 2rem;
  background: radial-gradient(circle at top right, rgba(37, 99, 235, 0.05), transparent 40%),
              radial-gradient(circle at bottom left, rgba(220, 38, 38, 0.03), transparent 30%);
}

.hero-content {
  text-align: center;
  margin-bottom: 2rem;
}

.badge-projua {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background-color: rgba(37, 99, 235, 0.08);
  color: var(--royal-blue);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-xl);
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  border: 1px solid rgba(37, 99, 235, 0.15);
  animation: pulse 2s infinite;
}

.hero-subtitle {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-top: 1rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.hero-cta {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.75rem;
  min-height: 48px; /* Mobile touch size */
  font-weight: 600;
  border-radius: var(--radius-md);
  transition: var(--transition-fast);
  cursor: pointer;
  border: none;
  font-size: 1rem;
}

.btn-primary {
  background-color: var(--royal-blue);
  color: #fff;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
}

.btn-primary:hover {
  background-color: #1d4ed8;
  transform: translateY(-2px);
}

.btn-secondary {
  background-color: #fff;
  color: var(--primary-navy);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  background-color: #f1f5f9;
  transform: translateY(-2px);
}

/* Info Banner */
.stats-banner {
  background-color: var(--primary-navy);
  color: #fff;
  padding: 2rem 1.5rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  margin-top: 2rem;
  position: relative;
  overflow: hidden;
}

.stats-banner::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 100%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.08) 0%, transparent 60%);
  pointer-events: none;
}

.stats-title {
  font-size: clamp(2.2rem, 8vw, 3.8rem);
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  line-height: 1;
}

.stats-title .plus {
  color: var(--brand-red);
}

.stats-title .sun-icon {
  width: 50px;
  height: 50px;
  background-color: var(--brand-yellow);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 15px var(--brand-yellow);
  position: relative;
  margin: 0 0.1rem;
}

.stats-title .sun-icon::before {
  content: '☀';
  color: var(--primary-navy);
  font-size: 2.2rem;
  font-weight: bold;
}

.stats-label {
  text-align: center;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--brand-yellow);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 0.25rem;
  margin-bottom: 1.5rem;
}

.stats-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-top: 1.5rem;
}

.stat-item {
  text-align: center;
}

.stat-num {
  font-size: 1.75rem;
  font-weight: 800;
  color: #fff;
}

.stat-desc {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.7);
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.05em;
}

/* ==========================================================================
   DASHBOARD SECTION (SEARCH & LIST)
   ========================================================================== */
.dashboard {
  padding: 3rem 0;
  background-color: #f1f5f9;
}

.section-header {
  margin-bottom: 2rem;
  text-align: center;
}

.section-header p {
  color: var(--text-muted);
  margin-top: 0.5rem;
}

/* Search Bar Wrapper */
.search-wrapper {
  background-color: var(--bg-card);
  padding: 1.25rem;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  margin-bottom: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.search-input-group {
  position: relative;
  flex: 1;
}

.search-input-group svg {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  width: 20px;
  height: 20px;
}

.search-input {
  width: 100%;
  height: 52px;
  padding: 0 1rem 0 3rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  background-color: #f8fafc;
  outline: none;
  font-size: 1rem;
  transition: var(--transition-fast);
}

.search-input:focus {
  border-color: var(--royal-blue);
  background-color: #fff;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

/* Filter Badges & Tags */
.filter-container {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.filter-label {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

.filter-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.filter-tag {
  background-color: #f1f5f9;
  border: 1px solid var(--border-color);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-xl);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-fast);
  min-height: 38px;
  display: inline-flex;
  align-items: center;
}

.filter-tag:hover {
  background-color: rgba(37, 99, 235, 0.05);
  border-color: rgba(37, 99, 235, 0.2);
}

.filter-tag.active {
  background-color: var(--royal-blue);
  color: #fff;
  border-color: var(--royal-blue);
  box-shadow: 0 4px 10px rgba(37, 99, 235, 0.25);
}

/* Dashboard Meta Info (Count of items) */
.results-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 500;
}

.dashboard-layout {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.map-wrapper {
  width: 100%;
  height: 320px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
  order: -1; /* Map first on mobile! */
  z-index: 10;
}

#map {
  width: 100%;
  height: 100%;
}

/* Custom Leaflet style overrides */
.leaflet-container {
  font-family: var(--font-family) !important;
}

.leaflet-popup-content-wrapper {
  border-radius: var(--radius-md) !important;
  box-shadow: var(--shadow-lg) !important;
  border: 1px solid var(--border-color);
}

.leaflet-popup-content {
  margin: 0.75rem 1rem !important;
}

.leaflet-popup-content h4 {
  font-weight: 800;
  color: var(--primary-navy);
  margin-bottom: 0.25rem;
  font-size: 0.95rem;
}

.leaflet-popup-content p {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 0;
}

/* Neighborhood Cards & Details */
.localities-grid {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.locality-card {
  background-color: var(--bg-card);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: var(--transition-normal);
}

.locality-card.expanded {
  box-shadow: var(--shadow-md);
  border-color: rgba(37, 99, 235, 0.3);
}

.locality-header {
  padding: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  user-select: none;
  min-height: 60px;
}

.locality-info {
  display: flex;
  flex-direction: column;
}

.locality-name {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--primary-navy);
}

.locality-stats {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
}

.locality-toggle-icon {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: transform var(--transition-fast);
}

.locality-card.expanded .locality-toggle-icon {
  transform: rotate(180deg);
  color: var(--royal-blue);
}

/* Expandable content area */
.locality-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s cubic-bezier(0, 1, 0, 1);
  border-top: 0px solid var(--border-color);
}

.locality-card.expanded .locality-content {
  max-height: 2000px; /* Large enough to fit content */
  transition: max-height 0.3s cubic-bezier(1, 0, 1, 0);
  border-top: 1px solid var(--border-color);
}

.works-list {
  padding: 1rem 1.25rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.work-item {
  background-color: #f8fafc;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  border-left: 4px solid var(--border-color);
  transition: var(--transition-fast);
}

.work-item.status-concluido {
  border-left-color: var(--brand-green);
}

.work-item.status-execucao {
  border-left-color: var(--brand-yellow);
}

.work-item.status-ordem {
  border-left-color: var(--royal-blue);
}

.work-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-main);
  line-height: 1.35;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-xl);
  width: fit-content;
}

.status-badge.concluido {
  background-color: rgba(16, 185, 129, 0.1);
  color: var(--brand-green);
}

.status-badge.execucao {
  background-color: rgba(234, 179, 8, 0.1);
  color: var(--brand-yellow);
}

.status-badge.ordem {
  background-color: rgba(37, 99, 235, 0.1);
  color: var(--royal-blue);
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  display: inline-block;
}

.status-badge.concluido .status-dot { background-color: var(--brand-green); }
.status-badge.execucao .status-dot { background-color: var(--brand-yellow); }
.status-badge.ordem .status-dot { background-color: var(--royal-blue); }

/* Empty state styling */
.empty-state {
  text-align: center;
  padding: 3rem 1rem;
  background-color: var(--bg-card);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  border: 1px dashed var(--border-color);
}

.empty-state svg {
  width: 48px;
  height: 48px;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.empty-state h3 {
  font-weight: 700;
  color: var(--primary-navy);
}

.empty-state p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-top: 0.25rem;
}

/* ==========================================================================
   SUBPROGRAMS SECTION
   ========================================================================== */
.subprograms {
  padding: 3rem 0;
  background-color: var(--bg-card);
}

.programs-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

.program-card {
  padding: 1.5rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-normal);
  display: flex;
  gap: 1rem;
}

.program-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(37, 99, 235, 0.2);
}

.program-icon-box {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background-color: rgba(37, 99, 235, 0.08);
  color: var(--royal-blue);
  font-size: 1.5rem;
}

.program-info {
  display: flex;
  flex-direction: column;
}

.program-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary-navy);
  margin-bottom: 0.35rem;
}

.program-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.45;
}

/* ==========================================================================
   FEATURED WORKS GALLERY
   ========================================================================== */
.featured {
  padding: 3rem 0;
  background-color: var(--bg-main);
}

.featured-card {
  background-color: var(--bg-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
  max-width: 600px;
  margin: 0 auto;
}

.featured-img-container {
  position: relative;
  aspect-ratio: 16 / 9;
  background-color: #e2e8f0;
  overflow: hidden;
}

.featured-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-normal);
}

.featured-card:hover .featured-img {
  transform: scale(1.03);
}

.featured-badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background-color: var(--brand-green);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-xl);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  box-shadow: var(--shadow-sm);
}

.featured-details {
  padding: 1.5rem;
}

.featured-tag {
  color: var(--royal-blue);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.5rem;
  display: block;
}

.featured-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--primary-navy);
  margin-bottom: 0.5rem;
  line-height: 1.25;
}

.featured-desc {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.45;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.footer {
  background-color: var(--primary-navy);
  color: #fff;
  padding: 3rem 0 2rem;
  border-top: 4px solid var(--brand-red);
}

.footer-top {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.logo-prefeitura-footer-img {
  height: 52px;
  width: auto;
  align-self: flex-start;
}

.logo-projua-footer-img {
  height: 32px;
  width: auto;
  align-self: flex-start;
}

.footer-desc {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.5;
  max-width: 320px;
}

.footer-qr-container {
  display: flex;
  align-items: center;
  gap: 1rem;
  background-color: rgba(255, 255, 255, 0.05);
  padding: 1rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.1);
  width: fit-content;
}

.qr-code {
  width: 72px;
  height: 72px;
  background-color: #fff;
  border-radius: var(--radius-sm);
  padding: 0.25rem;
}

.qr-info h4 {
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 0.15rem;
}

.qr-info p {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.6);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  text-align: center;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.5);
}

.social-links {
  display: flex;
  gap: 1rem;
}

.social-icon {
  width: 36px;
  height: 36px;
  background-color: rgba(255, 255, 255, 0.08);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  transition: var(--transition-fast);
}

.social-icon:hover {
  background-color: var(--royal-blue);
  transform: translateY(-2px);
}

/* ==========================================================================
   VIDEO PRESENTATION SECTION
   ========================================================================== */
.video-section {
  padding: 3rem 0;
  background-color: var(--bg-card);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.video-player-container {
  max-width: 720px;
  margin: 0 auto;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
  background-color: #000;
  aspect-ratio: 16 / 9;
}

.video-element {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ==========================================================================
   ANIMATIONS
   ========================================================================== */
@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.02); box-shadow: 0 0 10px rgba(37, 99, 235, 0.1); }
  100% { transform: scale(1); }
}

/* ==========================================================================
   BREAKPOINTS - RESPONSIVE DESIGN (Mobile First adaptation)
   ========================================================================== */

/* Tablet & Smaller Desktop Viewports (768px+) */
@media (min-width: 768px) {
  .container {
    max-width: 720px;
    padding-left: 2rem;
    padding-right: 2rem;
  }
  
  .hero {
    padding: 4rem 0 3rem;
  }
  
  .hero-cta {
    flex-direction: row;
    justify-content: center;
  }
  
  .stats-banner {
    padding: 2.5rem 3rem;
  }
  
  .stats-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
  }
  
  .search-wrapper {
    flex-direction: row;
    align-items: center;
    padding: 1rem 1.5rem;
  }
  
  .filter-container {
    flex-direction: row;
    align-items: center;
    gap: 1rem;
  }
  
  .filter-tags {
    flex: 1;
  }
  
  .programs-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .footer-top {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

/* Desktop Viewports (1024px+) */
@media (min-width: 1024px) {
  .container {
    max-width: 960px;
  }
  
  /* Show Desktop Menu & Hide Hamburger Toggle */
  .nav-toggle {
    display: none;
  }
  
  .nav-menu {
    position: static;
    height: auto;
    width: auto;
    max-width: none;
    flex-direction: row;
    background-color: transparent;
    box-shadow: none;
    padding: 0;
    gap: 1rem;
  }
  
  .nav-link {
    font-size: 0.95rem;
    padding: 0.5rem 1rem;
  }
  
  .hero-content {
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
  }
  
  .dashboard-layout {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 1.5rem;
  }

  .localities-grid {
    width: 55%;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
  }
  
  .map-wrapper {
    width: 45%;
    height: 550px;
    position: sticky;
    top: 90px;
    order: 1; /* Map on the right on desktop */
  }
  
  .locality-card {
    height: fit-content;
  }
  
  .programs-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .featured-card {
    max-width: 100%;
    display: flex;
    align-items: center;
  }
  
  .featured-img-container {
    width: 50%;
    aspect-ratio: 16/10;
  }
  
  .featured-details {
    width: 50%;
    padding: 2.5rem;
  }
}

/* Large Screens (1280px+) */
@media (min-width: 1280px) {
  .container {
    max-width: 1200px;
  }
  
  .localities-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
  }
}
