/* Responsive Design - Mobile First */

/* Extra Small Devices (Phones) */
@media (max-width: 575.98px) {
  :root {
    --font-size-h1: 28px;
    --font-size-h2: 24px;
    --font-size-h3: 20px;
    --font-size-h4: 18px;
    --section-padding: 40px 0;
  }
  
  .hero-section h1 {
    padding-top: 150px;
}

.hero-section {
    min-height: 70vh;
    text-align: center;
  }
  
  .hero-title {
    font-size: 24px;
  }
  
  .hero-subtitle {
    font-size: 18px;
  }
  
  .services-item img {
    height: 150px;
  }
  
  .team-member img {
    width: 200px;
    height: 200px;
  }
  
  .contact-form {
    padding: 2rem 1rem;
  }
  
  .navbar-collapse {
    background: rgba(255, 255, 255, 0.98);
    margin-top: 1rem;
    border-radius: 10px;
    padding: 1rem;
  }
  
  .gallery-grid {
    grid-template-columns: 1fr;
  }
  
  .gallery-item img {
    height: 200px;
  }
}

/* Small Devices (Landscape Phones) */
@media (min-width: 576px) and (max-width: 767.98px) {
  .hero-section h1 {
    padding-top: 150px;
}

.hero-section {
    min-height: 80vh;
  }
  
  .services-item img {
    height: 180px;
  }
  
  .team-member img {
    width: 220px;
    height: 220px;
  }
  
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Medium Devices (Tablets) */
@media (min-width: 768px) and (max-width: 991.98px) {
  .hero-section h1 {
    padding-top: 150px;
}

.hero-section {
    min-height: 90vh;
  }
  
  .services-item img {
    height: 190px;
  }
  
  .team-member img {
    width: 240px;
    height: 240px;
  }
  
  .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Large Devices (Desktops) */
@media (min-width: 992px) and (max-width: 1199.98px) {
  .gallery-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* Extra Large Devices */
@media (min-width: 1200px) {
  .gallery-grid {
    grid-template-columns: repeat(4, 1fr);
  }
  
  .container-fluid {
    max-width: 1400px;
    margin: 0 auto;
  }
}

/* Height-based Media Queries */
@media (max-height: 600px) {
  .hero-section h1 {
    padding-top: 150px;
}

.hero-section {
    min-height: 100vh;
    padding: 2rem 0;
  }
}

/* Landscape Mobile */
@media (max-width: 767px) and (orientation: landscape) {
  .hero-section h1 {
    padding-top: 150px;
}

.hero-section {
    min-height: 100vh;
    padding: 1rem 0;
  }
  
  .hero-title {
    font-size: 22px;
  }
  
  .hero-subtitle {
    font-size: 16px;
  }
}

/* Print Styles */
@media print {
  .navbar,
  .footer,
  .contact-form,
  .btn {
    display: none !important;
  }
  
  .hero-section h1 {
    padding-top: 150px;
}

.hero-section {
    min-height: auto;
    padding: 2rem 0;
  }
  
  * {
    color: #000 !important;
    background: #fff !important;
  }
}

/* High DPI Displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  .hero-section::before {
    background-image: url('../FAH_images/hero-bg@2x.webp');
  }
}

/* Dark Mode Preference (Optional) */
@media (prefers-color-scheme: dark) {
  /* Note: Not implementing dark theme per requirements */
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  .hero-section::before,
  .services-item,
  .about-feature,
  .features-item,
  .priceplan-item,
  .blog-item,
  .gallery-item {
    transition: none !important;
  }
  
  .fade-in,
  .slide-in-left,
  .slide-in-right {
    transition: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}

/* Container Adjustments */
@media (max-width: 575.98px) {
  .container,
  .container-fluid {
    padding-left: 15px;
    padding-right: 15px;
  }
}

/* Navigation Responsive */
@media (max-width: 991.98px) {
  .navbar-nav {
    text-align: center;
  }
  
  .navbar-nav .nav-link {
    padding: 0.5rem 1rem;
    margin: 0;
  }
}

/* Form Responsive */
@media (max-width: 767.98px) {
  .contact-form .form-control {
    font-size: 16px; /* Prevents zoom on iOS */
  }
}

/* Services Grid Responsive */
@media (max-width: 575.98px) {
  .services-item {
    margin-bottom: 1.73rem;
  }
}

@media (min-width: 576px) and (max-width: 767.98px) {
  .services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }
}

@media (min-width: 768px) {
  .services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
  }
}

@media (min-width: 992px) {
  .services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
  }
}

/* Team Grid Responsive */
@media (min-width: 576px) {
  .team-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }
}

@media (min-width: 768px) {
  .team-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
  }
}

@media (min-width: 992px) {
  .team-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 2rem;
  }
}

/* Price Plan Responsive */
@media (min-width: 768px) {
  .priceplan-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
  }
}

/* Reviews Responsive */
@media (min-width: 768px) {
  .reviews-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }
}

@media (min-width: 992px) {
  .reviews-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
  }
}

/* Blog Grid Responsive */
@media (min-width: 576px) {
  .blog-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }
}

@media (min-width: 768px) {
  .blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
  }
}

/* Accessibility Improvements */
@media (max-width: 767.98px) {
  .btn {
    min-height: 44px; /* Touch target size */
    min-width: 44px;
  }
  
  .nav-link {
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
}

/* Specific Component Adjustments */
@media (max-width: 575.98px) {
  .about-feature,
  .features-item,
  .coreinfo-item {
    padding: 1.5rem;
  }
  
  .services-item,
  .priceplan-item {
    padding: 1.5rem;
  }
  
  .timeline-item,
  .career-item,
  .casestudy-item {
    padding: 1.5rem;
  }
  
  .process-item,
  .reviews-item {
    padding: 1.5rem;
  }
} 