/* Mobile First Responsive Design */

/* Extra Small Devices (phones, less than 576px) */
@media (max-width: 575.98px) {
    /* Typography Adjustments */
    .display-5 {
        font-size: 1.8rem;
    }
    
    h2 {
        font-size: 1.6rem;
    }
    
    .lead {
        font-size: 1rem;
    }
    
    /* Navbar */
    .navbar-brand {
        font-size: 1.3rem;
    }
    
    .navbar-toggler {
        border: none;
        padding: 4px 8px;
    }
    
    /* Hero Section */
    .hero-section {
        min-height: 100vh;
        padding-top: 80px;
        text-align: center;
    }
    
    .hero-section .col-lg-6:first-child {
        margin-bottom: 2rem;
    }
    
    /* Cards */
    .card-body {
        padding: 1rem;
    }
    
    /* Buttons */
    .btn-lg {
        padding: 10px 25px;
        font-size: 1rem;
    }
    
    /* Services Grid */
    .services .col-md-6 {
        margin-bottom: 1.5rem;
    }
    
    /* Team Members */
    .team .col-md-6 {
        margin-bottom: 2rem;
    }
    
    /* Process Steps */
    .process .col-lg-2 {
        margin-bottom: 2rem;
    }
    
    /* Contact Form */
    .contact .col-md-6 {
        margin-bottom: 1rem;
    }
    
    /* Gallery */
    .gallery .col-6 {
        padding: 0.25rem;
    }
    
    /* Footer */
    footer .col-lg-4 {
        text-align: center;
        margin-bottom: 2rem;
    }
    
    /* Spacing Adjustments */
    .py-5 {
        padding-top: 3rem;
        padding-bottom: 3rem;
    }
    
    .mb-5 {
        margin-bottom: 2rem;
    }
    
    /* No animations on mobile for performance */
    * {
        animation: none !important;
        transition: none !important;
    }
    
    /* Hide decorative elements */
    .hero-section::before {
        display: none;
    }
}

/* Small Devices (landscape phones, 576px and up) */
@media (min-width: 576px) and (max-width: 767.98px) {
    .display-5 {
        font-size: 2.2rem;
    }
    
    .hero-section {
        padding-top: 90px;
    }
    
    .card-body {
        padding: 1.25rem;
    }
    
    /* No scroll animations on mobile */
    [data-sal] {
        transform: none !important;
        opacity: 1 !important;
    }
}

/* Medium Devices (tablets, 768px and up) */
@media (min-width: 768px) and (max-width: 991.98px) {
    .hero-section {
        padding-top: 100px;
    }
    
    .display-5 {
        font-size: 2.3rem;
    }
    
    /* Team grid adjustments */
    .team .col-lg-2 {
        flex: 0 0 auto;
        width: 20%;
    }
    
    /* Process steps */
    .process .col-lg-2 {
        flex: 0 0 auto;
        width: 20%;
    }
    
    /* Reduce scroll animations intensity */
    [data-sal="slide-left"],
    [data-sal="slide-right"] {
        --sal-translate-x: 20px;
    }
}

/* Large Devices (desktops, 992px and up) */
@media (min-width: 992px) and (max-width: 1199.98px) {
    .hero-section {
        padding-top: 120px;
    }
    
    .container {
        max-width: 960px;
    }
}

/* Extra Large Devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
    .hero-section {
        padding-top: 140px;
    }
    
    .container {
        max-width: 1140px;
    }
    
    /* Enhanced hover effects for larger screens */
    .card:hover {
        transform: translateY(-8px);
    }
    
    .btn:hover {
        transform: translateY(-3px);
    }
}

/* Landscape Orientation Adjustments */
@media (orientation: landscape) and (max-height: 568px) {
    .hero-section {
        min-height: auto;
        padding: 2rem 0;
    }
    
    .py-5 {
        padding-top: 2rem;
        padding-bottom: 2rem;
    }
}

/* High DPI Display Optimizations */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .card-img-top,
    .gallery img {
        image-rendering: crisp-edges;
    }
}

/* Print Styles */
@media print {
    .navbar,
    .btn,
    footer,
    .gallery {
        display: none;
    }
    
    body {
        color: black;
        background: white;
    }
    
    .hero-section {
        background: none;
        color: black;
    }
    
    .card {
        border: 1px solid #e4e4e4;
        break-inside: avoid;
    }
}

/* Accessibility - Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .hero-section::before {
        animation: none;
    }
    
    .card:hover {
        transform: none;
    }
    
    .btn:hover {
        transform: none;
    }
    
    [data-sal] {
        transform: none !important;
        opacity: 1 !important;
    }
    
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Dark Mode Support */

/* Container Adjustments for Very Large Screens */
@media (min-width: 1400px) {
    .container {
        max-width: 1320px;
    }
    
    .hero-section {
        padding-top: 160px;
    }
    
    .display-5 {
        font-size: 3rem;
    }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
    .card:hover {
        transform: none;
    }
    
    .btn:hover {
        transform: none;
    }
    
    /* Larger touch targets */
    .btn {
        min-height: 44px;
        min-width: 44px;
    }
    
    .nav-link {
        padding: 1rem;
    }
}

/* Mobile Navigation Improvements */
@media (max-width: 991.98px) {
    .navbar-collapse {
        background-color: rgba(255, 255, 255, 0.98);
        border-radius: 10px;
        margin-top: 1rem;
        padding: 1rem;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    }
    
    .navbar-nav .nav-link {
        padding: 0.75rem 1rem;
        border-bottom: 1px solid var(--border-color);
    }
    
    .navbar-nav .nav-link:last-child {
        border-bottom: none;
    }
}

/* Image Optimization for Mobile */
@media (max-width: 767.98px) {
    .card-img-top {
        height: 180px;
    }
    
    .gallery img {
        border-radius: 5px;
    }
    
    .hero-section img {
        max-width: 100%;
        height: auto;
        margin-top: 1rem;
    }
}

/* Form Responsiveness */
@media (max-width: 575.98px) {
    .form-control {
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    .btn-lg {
        width: 100%;
        margin-top: 1rem;
    }
}

/* Team Section Mobile Layout */
@media (max-width: 991.98px) {
    .team .col-lg-2 {
        flex: 0 0 auto;
        width: 50%;
        margin-bottom: 2rem;
    }
}

@media (max-width: 575.98px) {
    .team .col-lg-2 {
        width: 100%;
        margin-bottom: 1.5rem;
    }
}

/* Process Section Mobile Stacking */
@media (max-width: 991.98px) {
    .process .col-lg-2 {
        flex: 0 0 auto;
        width: 50%;
        margin-bottom: 2rem;
    }
    
    .process-step::after {
        display: none;
    }
}

@media (max-width: 575.98px) {
    .process .col-lg-2 {
        width: 100%;
    }
} 

.hero-section h1 {
    padding-top: 175px;
}