/* Mobile First Responsive Design */

/* Extra Small devices (phones, less than 576px) */
@media (max-width: 575.98px) {
    /* Disable animations on mobile */
    * {
        animation: none !important;
        transition: none !important;
    }
    
    /* Typography adjustments */
    .display-4 {
        font-size: 2rem;
    }
    
    h1, .h1 {
        font-size: 1.8rem;
    }
    
    .lead {
        font-size: 1rem;
    }
    
    .navbar-brand {
        font-size: 1.2rem;
    }
    
    /* Hero section */
    #hero {
        padding-top: 2rem;
        padding-bottom: 2rem;
    }
    
    #hero .display-4 {
        margin-bottom: 1rem;
    }
    
    /* Decorative shapes - hide on mobile */
    #hero .position-absolute {
        display: none;
    }
    
    /* Buttons */
    .btn-lg {
        font-size: 1rem;
        padding: 0.75rem 1.5rem;
    }
    
    /* Cards */
    .card:hover {
        transform: none;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    }
    
    /* Team images */
    #team img {
        width: 120px !important;
        height: 120px !important;
    }
    
    /* Gallery adjustments */
    #gallery .col-lg-4:nth-child(even),
    #gallery .col-lg-4:nth-child(3n) {
        margin-top: 0;
    }
    
    /* Timeline */
    .timeline::before {
        left: 15px;
    }
    
    /* Process steps */
    #process .rounded-circle {
        width: 60px !important;
        height: 60px !important;
    }
    
    /* Contact form */
    .form-control {
        font-size: 16px; /* Prevents zoom on iOS */
    }
}

/* Small devices (landscape phones, 576px and up) */
@media (min-width: 576px) and (max-width: 767.98px) {
    /* Disable animations on small tablets */
    * {
        animation: none !important;
        transition: none !important;
    }
    
    .display-4 {
        font-size: 2.2rem;
    }
    
    #hero .decorative-shape {
        font-size: 8rem !important;
    }
}

/* Medium devices (tablets, 768px and up) */
@media (min-width: 768px) and (max-width: 991.98px) {
    .display-4 {
        font-size: 2.5rem;
    }
    
    /* Services grid */
    #services .row {
        margin-bottom: 2rem;
    }
    
    /* Team layout */
    #team .col-md-6 {
        margin-bottom: 2rem;
    }
}

/* Large devices (desktops, 992px and up) */
@media (min-width: 992px) and (max-width: 1199.98px) {
    .container {
        max-width: 960px;
    }
}

/* Extra large devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
    .container {
        max-width: 1140px;
    }
    
    /* Enhanced spacing for large screens */
    section {
        padding: 6rem 0;
    }
}

/* Print styles */
@media print {
    .navbar,
    #footer,
    .btn,
    .position-absolute {
        display: none !important;
    }
    
    body {
        color: #000 !important;
        background: #fff !important;
    overflow-x: hidden;
}
    
    .card {
        border: 1px solid #000 !important;
        box-shadow: none !important;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #0056b3;
        --primary-dark: #004085;
    }
    
    .btn-outline-primary {
        border-width: 2px;
    }
    
    .card {
        border: 2px solid #dee2e6;
    }
}

/* Reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Dark mode support */

/* Focus management for accessibility */
@media (max-width: 767.98px) {
    .navbar-toggler:focus {
        box-shadow: 0 0 0 0.2rem rgba(74, 144, 226, 0.5);
    }
    
    /* Ensure touch targets are at least 44px */
    .btn,
    .nav-link,
    .navbar-toggler {
        min-height: 44px;
        min-width: 44px;
    }
}

/* Landscape orientation adjustments */
@media (orientation: landscape) and (max-height: 500px) {
    #hero {
        min-height: 100vh;
        padding: 2rem 0;
    }
    
    .navbar {
        padding: 0.25rem 0;
    }
}

/* Hover states only for devices that support hover */
@media (hover: hover) and (pointer: fine) {
    .card:hover {
        transform: translateY(-5px);
        box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    }
    
    #gallery a:hover {
        transform: scale(1.05);
    }
    
    #team img:hover {
        transform: scale(1.1);
    }
}

/* Touch device specific styles */
@media (hover: none) and (pointer: coarse) {
    .card:hover,
    #gallery a:hover,
    #team img:hover {
        transform: none;
    }
    
    /* Larger touch targets */
    .btn {
        padding: 0.75rem 1.5rem;
    }
    
    .nav-link {
        padding: 0.75rem 1rem;
    }
} 