/* Responsive CSS - Mobile First Approach */

/* Extra Small Devices (phones, 576px and down) */
@media (max-width: 575.98px) {
    /* Typography Adjustments */
    .navbar-brand {
        font-size: 1.1rem;
    }
    
    h1, .display-4 {
        font-size: 1.75rem;
        line-height: 1.3;
    }
    
    h2, .h2 {
        font-size: 1.5rem;
        line-height: 1.4;
    }
    
    h3, .h3 {
        font-size: 1.25rem;
    }
    
    /* Hero Section */
    .hero-section {
        min-height: 70vh;
        padding: 1rem 0;
    }
    
    .hero-section .container {
        padding: 0 1rem;
    }
    
    /* Cards */
    .card-img-top {
        height: 180px;
    }
    
    .card-body {
        padding: 1rem;
    overflow-x: hidden;
}
    
    /* Team Images */
    .rounded-circle {
        width: 80px;
        height: 80px;
    }
    
    /* Contact Form */
    .form-control {
        padding: 0.5rem 0.75rem;
        font-size: 0.9rem;
    }
    
    .btn-lg {
        padding: 0.5rem 1.5rem;
        font-size: 1rem;
    }
    
    /* Gallery */
    #gallery .col-lg-3 {
        margin-bottom: 1rem;
    }
    
    /* Process Steps */
    .process-step {
        margin-bottom: 2rem;
    }
    
    /* Footer */
    footer .container {
        text-align: center;
    }
    
    footer .col-lg-4 {
        margin-bottom: 2rem;
    }
}

/* Small Devices (landscape phones, 576px and up) */
@media (min-width: 576px) and (max-width: 767.98px) {
    /* Hero adjustments */
    .hero-section {
        min-height: 80vh;
    }
    
    /* Cards in services */
    .card-img-top {
        height: 200px;
    }
    
    /* Team layout */
    .rounded-circle {
        width: 90px;
        height: 90px;
    }
}

/* Medium Devices (tablets, 768px and up) */
@media (min-width: 768px) and (max-width: 991.98px) {
    /* Navigation */
    .navbar-nav {
        margin-top: 1rem;
    }
    
    /* Hero Section */
    .hero-section {
        min-height: 90vh;
    }
    
    /* Services Grid */
    .services-grid .col-md-6 {
        margin-bottom: 2rem;
    }
    
    /* Team Images */
    .rounded-circle {
        width: 100px;
        height: 100px;
    }
    
    /* Contact Section */
    .contact-info {
        margin-top: 2rem;
    }
}

/* Large Devices (desktops, 992px and up) */
@media (min-width: 992px) {
    /* Full height hero */
    .hero-section {
        min-height: 100vh;
    }
    
    /* Enhanced card hover effects */
    .card:hover {
        transform: translateY(-8px);
        box-shadow: 0 12px 30px rgba(0,0,0,0.2);
    }
    
    /* Team layout optimization */
    .team-member {
        margin-bottom: 2rem;
    }
}

/* Extra Large Devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
    /* Container max-width adjustments */
    .container {
        max-width: 1140px;
    }
    
    /* Enhanced spacing */
    section {
        padding: 5rem 0;
    }
    
    /* Larger hero text */
    .hero-section h1 {
        font-size: 3rem;
    padding-top: 150px;
}
    
    .hero-section .lead {
        font-size: 1.25rem;
    }
}

/* Landscape Orientation */
@media (orientation: landscape) and (max-height: 600px) {
    .hero-section {
        min-height: 100vh;
        padding: 2rem 0;
    }
    
    .navbar {
        padding: 0.5rem 0;
    }
}

/* High DPI Displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    /* Enhance image quality */
    .card-img-top,
    .rounded-circle {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
    /* Larger touch targets */
    .btn {
        min-height: 44px;
        min-width: 44px;
        padding: 0.75rem 1.5rem;
    }
    
    .nav-link {
        padding: 1rem 0.5rem;
    }
    
    /* Remove hover effects for touch */
    .card:hover {
        transform: none;
        box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    }
    
    .btn-primary:hover {
        transform: none;
    }
    
    #gallery img:hover {
        transform: none;
        opacity: 1;
    }
}

/* Print Styles */
@media print {
    /* Hide non-essential elements */
    .navbar,
    footer,
    .btn,
    #gallery {
        display: none !important;
    }
    
    /* Optimize text for print */
    body {
        font-size: 12pt;
        line-height: 1.5;
        color: #000;
        background: #fff;
    }
    
    h1, h2, h3, h4, h5, h6 {
        color: #000;
        page-break-after: avoid;
    }
    
    /* Expand containers */
    .container {
        width: 100% !important;
        max-width: none !important;
    }
    
    /* Remove shadows and decorative elements */
    .card {
        box-shadow: none;
        border: 1px solid #ccc;
    }
}

/* Reduced Motion Preferences */
@media (prefers-reduced-motion: reduce) {
    /* Disable all animations and transitions */
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    /* Remove decorative transforms */
    .hero-section::before {
        display: none;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    /* Increase contrast for better accessibility */
    .card {
        border: 2px solid #000;
    }
    
    .btn-primary {
        border: 2px solid #000;
        color: #000;
        background: #fff;
    }
    
    .text-muted {
        color: #000 !important;
    }
}

/* Dark Mode Support */

/* Container Queries (Future-proofing) */
@container (max-width: 400px) {
    .card-body {
        padding: 0.75rem;
    }
    
    .card-title {
        font-size: 1rem;
    }
}

/* Specific Mobile Navigation Improvements */
@media (max-width: 991.98px) {
    /* Ensure hamburger menu works properly */
    .navbar-toggler {
        border: none;
        padding: 0.25rem 0.5rem;
    }
    
    .navbar-toggler:focus {
        box-shadow: 0 0 0 0.2rem rgba(74, 155, 142, 0.25);
    }
    
    .navbar-collapse {
        margin-top: 1rem;
        padding-top: 1rem;
        border-top: 1px solid rgba(0,0,0,0.1);
    }
    
    .navbar-nav .nav-item {
        margin: 0.25rem 0;
    }
    
    .navbar-nav .nav-link {
        padding: 0.75rem 1rem;
        border-radius: 8px;
        transition: background-color 0.3s ease;
    }
    
    .navbar-nav .nav-link:hover {
        background-color: rgba(74, 155, 142, 0.1);
    }
}

/* Gallery Responsive Grid */
@media (max-width: 575.98px) {
    #gallery .col-lg-3 {
        flex: 0 0 50%;
        max-width: 50%;
    }
}

@media (min-width: 576px) and (max-width: 767.98px) {
    #gallery .col-lg-3 {
        flex: 0 0 33.333333%;
        max-width: 33.333333%;
    }
}

/* Form Responsive Improvements */
@media (max-width: 767.98px) {
    .contact-form .row .col-md-6 {
        margin-bottom: 1rem;
    }
    
    .contact-info {
        text-align: center;
        padding: 1.5rem;
    }
    
    .contact-info i {
        font-size: 2rem;
    }
}

/* Services Grid Responsive */
@media (max-width: 575.98px) {
    .services-grid .col-lg-4 {
        margin-bottom: 1.5rem;
    }
}

@media (min-width: 576px) and (max-width: 991.98px) {
    .services-grid .col-lg-4 {
        flex: 0 0 50%;
        max-width: 50%;
        margin-bottom: 2rem;
    }
} 