/* Smart City Bike-Lane Analytics Dashboard - Responsive CSS */

/* Mobile First Approach */

/* Extra Small devices (portrait phones, less than 576px) */
@media (max-width: 575.98px) {
  /* Typography adjustments */
  h1 { font-size: 1.53rem; }
  h2 { font-size: 1.43rem; }
  h3 { font-size: 1.26rem; }
  
  /* Hero section */
  #hero {
    min-height: 70vh;
    text-align: center;
  }
  
  #hero h1 {
    font-size: 1.77rem;
    margin-bottom: 1rem;
  }
  
  #hero p {
    font-size: 1rem;
  }
  
  /* Navigation */
  .navbar-brand {
    font-size: 1rem;
  }
  
  .navbar-nav {
    text-align: center;
    margin-top: 1rem;
  }
  
  /* Sections padding */
  section {
    padding: 2rem 0;
  }
  
  /* Cards */
  .feature-card,
  .service-card,
  .price-card {
    margin-bottom: 1.70rem;
  }
  
  /* Team cards */
  .team-photo {
    height: 200px;
  }
  
  /* Contact form */
  .contact-form {
    padding: 1.5rem;
  }
  
  /* Gallery */
  .gallery-layout {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }
  
  /* Footer */
  footer {
    text-align: center;
  }
  
  .footer-section {
    margin-bottom: 1.69rem;
  }
}

/* Small devices (landscape phones, 576px and up) */
@media (min-width: 576px) and (max-width: 767.98px) {
  /* Hero adjustments */
  #hero {
    min-height: 80vh;
  }
  
  #hero h1 {
    font-size: 1.90rem;
  }
  
  /* Gallery */
  .gallery-layout {
    grid-template-columns: repeat(2, 1fr);
  }
  
  /* Services */
  .service-card {
    margin-bottom: 1.57rem;
  }
  
  /* Process steps */
  .process-step {
    margin: 0.5rem 0;
  }
}

/* Medium devices (tablets, 768px and up) */
@media (min-width: 768px) and (max-width: 991.98px) {
  /* Hero */
  #hero {
    min-height: 85vh;
  }
  
  #hero h1 {
    font-size: 2.01rem;
  }
  
  /* Gallery */
  .gallery-layout {
    grid-template-columns: repeat(3, 1fr);
  }
  
  /* Features grid */
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  /* Team cards in rows of 2 */
  .team-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }
  
  /* Price cards */
  .price-card {
    margin-bottom: 1rem;
  }
}

/* Large devices (desktops, 992px and up) */
@media (min-width: 992px) and (max-width: 1199.98px) {
  /* Gallery */
  .gallery-layout {
    grid-template-columns: repeat(4, 1fr);
  }
  
  /* Features */
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  /* Team layout */
  .team-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
  }
  
  /* Services layout */
  .services-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
  }
}

/* Extra large devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
  /* Hero full treatment */
  #hero {
    min-height: 100vh;
  }
  
  #hero h1 {
    font-size: 2.30rem;
  }
  
  /* Gallery full grid */
  .gallery-layout {
    grid-template-columns: repeat(5, 1fr);
    gap: 1.5rem;
  }
  
  /* Features full grid */
  .features-grid {
    grid-template-columns: repeat(4, 1fr);
  }
  
  /* Services full grid */
  .services-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
  }
  
  /* Team full grid */
  .team-container {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1.5rem;
  }
  
  /* Core info grid */
  .coreinfo-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
  }
}

/* Landscape orientation adjustments */
@media (orientation: landscape) and (max-height: 500px) {
  #hero {
    min-height: 90vh;
  }
  
  section {
    padding: 2rem 0;
  }
}

/* High DPI displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  .team-photo,
  .gallery-image,
  img[src*=".webp"] {
    image-rendering: crisp-edges;
  }
}

/* Print styles */
@media print {
  * {
    background: white;
    color: black;
    box-shadow: none;
  }
  
  header,
  footer,
  .btn,
  .contact-form {
    display: none;
  }
  
  section {
    page-break-inside: avoid;
    padding: 1rem 0;
  }
  
  .container {
    max-width: none;
  }
}

/* Accessibility - Focus states */
@media (prefers-reduced-motion: no-preference) {
  .feature-card,
  .service-card,
  .team-card,
  .blog-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
  }
}

/* Focus indicators */
button:focus,
.btn:focus,
.form-control:focus,
a:focus {
  outline: 2px solid var(--secondary-green);
  outline-offset: 2px;
}

/* Ensure proper spacing on mobile */
@media (max-width: 575.98px) {
  .process-step::before {
    display: none;
  }
  
  .timeline-item {
    border-left: none;
    border-top: 4px solid var(--accent-orange);
  }
}

/* Dark mode support (optional, but not implemented per requirements) */

/* Container max-widths for ultra-wide screens */
@media (min-width: 1400px) {
  .container,
  .container-lg,
  .container-md,
  .container-sm,
  .container-xl,
  .container-xxl {
    max-width: 1320px;
  }
}

/* Specific mobile navigation improvements */
@media (max-width: 991.98px) {
  .navbar-collapse {
    background: rgba(48, 145, 203, 0.95);
    margin-top: 1rem;
    border-radius: 8px;
    padding: 1rem;
  }
  
  .navbar-nav .nav-link {
    padding: 0.5rem 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
  }
  
  .navbar-nav .nav-link:last-child {
    border-bottom: none;
  }
}

/* Improved touch targets for mobile */
@media (hover: none) and (pointer: coarse) {
  .btn,
  .nav-link,
  .card {
    min-height: 44px;
    min-width: 44px;
  }
  
  .form-control {
    min-height: 44px;
  }
}

/* Tablet-specific optimizations */
@media (min-width: 768px) and (max-width: 1024px) {
  .hero-content {
    padding: 2rem 0;
  }
  
  .section-title {
    margin-bottom: 2rem;
  }
  
  .card-body {
    padding: 1.25rem;
  }
} 