/* Responsive Design - Mobile First Approach */

/* Base styles are mobile-first (already defined in main.css) */

/* Small devices (landscape phones, 576px and up) */
@media (min-width: 576px) {
    .container {
        max-width: 540px;
    }
    
    .hero-section h1 {
        font-size: 2.25rem;
    }
    
    .feature-card {
        padding: 1.5rem;
    }
    
    .service-card .card-body {
        padding: 1.5rem;
    }
}

/* Medium devices (tablets, 768px and up) */
@media (min-width: 768px) {
    .container {
        max-width: 720px;
    }
    
    .hero-section h1 {
        font-size: 2.5rem;
    }
    
    .navbar-nav .nav-link {
        padding: 0.5rem 1rem !important;
    }
    
    .feature-item {
        margin-bottom: 2rem;
    }
    
    .contact-form {
        padding: 2.5rem;
    }
}

/* Large devices (desktops, 992px and up) */
@media (min-width: 992px) {
    .container {
        max-width: 960px;
    }
    
    .hero-section h1 {
        font-size: 3rem;
    }
    
    .hero-section p {
        font-size: 1.25rem;
    }
    
    .feature-card {
        padding: 2rem;
    }
    
    .service-card .card-body {
        padding: 2rem;
    }
    
    .feature-item {
        padding: 2rem;
    }
    
    .contact-form {
        padding: 3rem;
    }
}

/* Extra large devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
    .container {
        max-width: 1140px;
    }
    
    .hero-section h1 {
        font-size: 3.5rem;
    }
    
    .section-title h2 {
        font-size: 2.5rem;
    }
}

/* Extra extra large devices (extra large desktops, 1400px and up) */
@media (min-width: 1400px) {
    .container {
        max-width: 1320px;
    }
}

/* Mobile-specific styles */
@media (max-width: 575.98px) {
    .hero-section {
        padding: 3rem 0;
    }
    
    .hero-section h1 {
        font-size: 1.75rem;
    }
    
    .hero-section p {
        font-size: 1rem;
    }
    
    .feature-card {
        padding: 1.5rem;
        margin-bottom: 1.5rem;
    }
    
    .service-card {
        margin-bottom: 1.5rem;
    }
    
    .feature-item {
        flex-direction: column;
        text-align: center;
        padding: 1.5rem;
    }
    
    .feature-item i {
        margin-right: 0;
        margin-bottom: 1rem;
    }
    
    .contact-form {
        padding: 1.5rem;
    }
    
    .contact-form .form-control {
        margin-bottom: 1rem;
    }
    
    .navbar-brand {
        font-size: 1.125rem !important;
    }
    
    section {
        padding: 2rem 0;
    }
}

/* Tablet portrait styles */
@media (min-width: 576px) and (max-width: 991.98px) {
    .hero-section .row {
        flex-direction: column-reverse;
    }
    
    .hero-section .col-lg-6:first-child {
        text-align: center;
        margin-top: 2rem;
    }
    
    .feature-item {
        flex-direction: column;
        text-align: center;
    }
    
    .feature-item i {
        margin-right: 0;
        margin-bottom: 1rem;
    }
}

/* High DPI screens */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .hero-section img {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: optimize-contrast;
    }
    
    .service-card img {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: optimize-contrast;
    }
}

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

/* Print styles */
@media print {
    .navbar,
    .contact-form,
    footer {
        display: none !important;
    }
    
    .hero-section {
        background: white !important;
        color: black !important;
    }
    
    .hero-section::before {
        display: none !important;
    }
    
    .feature-card,
    .service-card {
        box-shadow: none !important;
        border: 1px solid #ddd !important;
    }
    
    a {
        color: inherit !important;
        text-decoration: none !important;
    }
    
    .btn {
        display: none !important;
    }
}

/* Accessibility - Reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
    .hero-section::before {
        animation: none !important;
    }
    
    .animate-fade-in-up,
    .animate-pulse {
        animation: none !important;
    }
    
    .feature-card:hover,
    .service-card:hover,
    .feature-item:hover {
        transform: none !important;
    }
    
    .contact-form .btn-primary:hover {
        transform: none !important;
    }
}

/* Dark mode support (if user prefers dark) */

/* Container adjustments for better mobile experience */
.container-fluid {
    padding-left: 1rem;
    padding-right: 1rem;
}

@media (max-width: 575.98px) {
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

/* Grid system adjustments */
@media (max-width: 767.98px) {
    .row > [class*="col-"] {
        margin-bottom: 1rem;
    }
    
    .row > [class*="col-"]:last-child {
        margin-bottom: 0;
    }
}

/* Form responsiveness */
@media (max-width: 767.98px) {
    .contact-form .row .col-md-6 {
        margin-bottom: 1rem;
    }
    
    .contact-form .row .col-md-6:last-child {
        margin-bottom: 0;
    }
}

/* Footer responsiveness */
@media (max-width: 767.98px) {
    footer .row .col-lg-4 {
        margin-bottom: 2rem;
        text-align: center;
    }
    
    footer .row .col-lg-4:last-child {
        margin-bottom: 0;
    }
}

/* Navigation responsiveness */
@media (max-width: 991.98px) {
    .navbar-collapse {
        background: rgba(255, 255, 255, 0.95);
        border-radius: 10px;
        padding: 1rem;
        margin-top: 1rem;
    }
    
    .navbar-nav .nav-link {
        color: var(--primary-green-dark) !important;
        padding: 0.5rem 0 !important;
        border-bottom: 1px solid rgba(46, 125, 50, 0.1);
    }
    
    .navbar-nav .nav-link:hover {
        color: var(--primary-orange) !important;
    }
    
    .navbar-nav .nav-link:last-child {
        border-bottom: none;
    }
}

/* Image responsiveness */
img {
    max-width: 100%;
    height: auto;
}

.hero-section img {
    width: 100%;
    max-width: 500px;
    height: auto;
}

.service-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

/* Flexbox utilities for responsive design */
.d-flex-mobile {
    display: flex;
}

@media (max-width: 767.98px) {
    .d-flex-mobile {
        flex-direction: column;
    }
}

/* Spacing adjustments for mobile */
@media (max-width: 575.98px) {
    .py-5 {
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }
    
    .my-4 {
        margin-top: 1.5rem !important;
        margin-bottom: 1.5rem !important;
    }
    
    .mt-5 {
        margin-top: 2rem !important;
    }
    
    .mb-5 {
        margin-bottom: 2rem !important;
    }
}

/* Button responsiveness */
@media (max-width: 575.98px) {
    .btn {
        width: 100%;
        padding: 0.75rem 1rem;
    }
    
    .contact-form .btn-primary {
        width: 100%;
        padding: 1rem;
    }
}

/* Text alignment for mobile */
@media (max-width: 767.98px) {
    .text-center-mobile {
        text-align: center !important;
    }
    
    .hero-section .col-lg-6 {
        text-align: center;
    }
} 