/* EcoMove - Responsive CSS */

/* Mobile First Approach */
/* Base styles for mobile devices (320px and up) */

/* Extra Small Devices (phones, 576px and down) */
@media (max-width: 575.98px) {
    /* Typography */
    .display-4 {
        font-size: 1.8rem;
        line-height: 1.3;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    h3 {
        font-size: 1.25rem;
    }
    
    .lead {
        font-size: 1rem;
    }
    
    /* Navigation */
    .navbar-brand {
        font-size: 1.25rem;
    }
    
    .navbar-nav {
        text-align: center;
        padding-top: 1rem;
    }
    
    .nav-link {
        padding: 0.75rem 1rem;
        font-size: 1rem;
    }
    
    /* Hero Section */
    #hero {
        padding-top: 100px;
        min-height: 80vh;
    }
    
    #hero .container {
        padding: 0 15px;
    }
    
    #hero .btn {
        width: 100%;
        margin-top: 1rem;
    }
    
    /* Cards */
    .card {
        margin-bottom: 1.5rem;
    }
    
    .card-body {
        padding: 1rem;
    overflow-x: hidden;
}
    
    /* Buttons */
    .btn-lg {
        padding: 10px 20px;
        font-size: 1rem;
    }
    
    /* Spacing */
    .py-5 {
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }
    
    /* Forms */
    .form-control {
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    /* Gallery */
    #gallery .col-4 {
        padding: 2px;
    }
    
    /* Team Section */
    .col-6 {
        margin-bottom: 1rem;
    }
    
    /* Timeline */
    .timeline-content {
        padding: 15px;
        margin-left: 10px;
    }
    
    /* Process Section */
    .col-md-4 {
        margin-bottom: 1.5rem;
    }
    
    /* Footer */
    #footer .col-lg-4 {
        text-align: center;
        margin-bottom: 2rem;
    }
    
    /* Contact Section */
    .row.g-5 > .col-lg-6 {
        margin-bottom: 2rem;
    }
}

/* Small Devices (landscape phones, 576px and up) */
@media (min-width: 576px) and (max-width: 767.98px) {
    .display-4 {
        font-size: 2rem;
    }
    
    #hero {
        min-height: 85vh;
    }
    
    .py-5 {
        padding-top: 2.5rem !important;
        padding-bottom: 2.5rem !important;
    }
    
    /* Cards in rows */
    .row.g-4 > .col-md-6 {
        margin-bottom: 1.5rem;
    }
}

/* Medium Devices (tablets, 768px and up) */
@media (min-width: 768px) and (max-width: 991.98px) {
    .display-4 {
        font-size: 2.25rem;
    }
    
    #hero {
        min-height: 90vh;
    }
    
    .py-5 {
        padding-top: 3rem !important;
        padding-bottom: 3rem !important;
    }
    
    /* Navigation */
    .navbar-nav {
        margin-left: auto;
    }
    
    /* Hero content adjustment */
    #hero .col-lg-6:first-child {
        margin-bottom: 2rem;
    }
    
    /* Services grid */
    .col-lg-4.col-md-6 {
        margin-bottom: 2rem;
    }
    
    /* Team section */
    .col-lg-2.col-md-4 {
        margin-bottom: 1.5rem;
    }
}

/* Large Devices (desktops, 992px and up) */
@media (min-width: 992px) and (max-width: 1199.98px) {
    .container {
        max-width: 960px;
    }
    
    .display-4 {
        font-size: 2.5rem;
    }
    
    /* Team section - adjust for 5 members */
    #team .row {
        justify-content: center;
    }
    
    #team .col-lg-2:last-child {
        margin-left: auto;
        margin-right: auto;
    }
}

/* Extra Large Devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
    .container {
        max-width: 1140px;
    }
    
    .display-4 {
        font-size: 2.75rem;
    }
    
    /* Enhanced spacing for large screens */
    .py-5 {
        padding-top: 4rem !important;
        padding-bottom: 4rem !important;
    }
}

/* Mobile-specific animations disabled */
@media (max-width: 768px) {
    @media (prefers-reduced-motion: no-preference) {
        
        .card:hover {
            transform: none;
        }
        
        #gallery img:hover {
            transform: none;
        }
    }
}

/* Landscape orientation adjustments */
@media (orientation: landscape) and (max-height: 500px) {
    #hero {
        min-height: 100vh;
        padding-top: 80px;
    }
    
    .navbar {
        padding: 0.25rem 0;
    }
    
    .py-5 {
        padding-top: 1.5rem !important;
        padding-bottom: 1.5rem !important;
    }
}

/* Print Styles */
@media print {
    .navbar,
    #footer,
    .btn {
        display: none !important;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.4;
    }
    
    .container {
        max-width: none !important;
    }
    
    .card {
        border: 1px solid #ccc !important;
        break-inside: avoid;
    }
}

/* High DPI/Retina Displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    /* Optimize for high-resolution displays */
    .card {
        border-width: 0.5px;
    }
    
    .timeline::before {
        width: 1px;
    }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
    /* Remove hover effects on touch devices */
    .card:hover {
        transform: none;
        box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
    }
    
    .btn:hover {
        transform: none;
    }
    
    #gallery img:hover {
        transform: none;
        filter: none;
    }
    
    /* Increase touch targets */
    .btn {
        min-height: 44px;
        min-width: 44px;
    }
    
    .nav-link {
        padding: 1rem;
    }
    
    .form-control {
        min-height: 44px;
    }
}

/* Dark Mode Support */

/* Reduced Motion Preferences */
@media (prefers-reduced-motion: reduce) {
    .card,
    .btn,
    #gallery img,
    .timeline-content,
    .form-control {
        transition: none !important;
    }
    
}

/* Container Queries (Future-proofing) */
@supports (container-type: inline-size) {
    .card-container {
        container-type: inline-size;
    }
    
    @container (max-width: 300px) {
        .card-body {
            padding: 0.75rem;
        }
        
        .card-title {
            font-size: 1rem;
        }
    }
}

/* Accessibility - Focus Management */
@media (max-width: 768px) {
    .skip-link {
        position: absolute;
        top: -40px;
        left: 6px;
        background: var(--primary-color);
        color: white;
        padding: 8px;
        text-decoration: none;
        border-radius: 0 0 4px 4px;
        z-index: 1000;
    }
    
    .skip-link:focus {
        top: 0;
    }
} 