/* Responsive Design - Mobile First Approach */

/* Extra Small Devices (portrait phones, less than 576px) */
@media (max-width: 575.98px) {
    .container {
        padding-left: 15px;
        padding-right: 15px;
    }
    
    /* Typography */
    h1 {
        font-size: 1.82rem;
    }
    
    h2 {
        font-size: 1.51rem;
    }
    
    h3 {
        font-size: 1.40rem;
    }
    
    /* Hero Section */
    #hero {
        min-height: 80vh;
        padding: 2rem 0;
    }
    
    #hero .col-lg-6 {
        text-align: center;
        margin-bottom: 2rem;
    }
    
    /* Navigation */
    .navbar-brand {
        font-size: 1.27rem;
    }
    
    .navbar-nav {
        text-align: center;
        margin-top: 1rem;
    }
    
    /* Cards */
    .card {
        margin-bottom: 1.63rem;
    }
    
    .card-body {
        padding: 1.5rem;
    }
    
    /* Buttons */
    .btn {
        width: 100%;
        margin-bottom: 0.67rem;
    }
    
    /* Contact Form */
    .contact-info {
        margin-top: 2rem;
        order: 2;
    }
    
    /* Team Section */
    .team img {
        width: 100px;
        height: 100px;
    }
    
    /* Footer */
    footer .col-lg-4 {
        text-align: center;
        margin-bottom: 2rem;
    }
    
    /* Gallery */
    #gallery .col-lg-3 {
        margin-bottom: 1rem;
    }
    
    /* Process Steps */
    .process-step,
    .timeline-item {
        width: 50px;
        height: 50px;
        font-size: 0.87rem;
    }
    
    /* Pricing */
    .priceplan .col-lg-4 {
        margin-bottom: 2rem;
    }
}

/* Small Devices (landscape phones, 576px and up) */
@media (min-width: 576px) and (max-width: 767.98px) {
    /* Hero Section */
    #hero {
        min-height: 85vh;
    }
    
    /* Cards in rows */
    .row .col-md-6 {
        margin-bottom: 2rem;
    }
    
    /* Contact Form Layout */
    .contact-form .col-md-6 {
        margin-bottom: 1rem;
    }
    
    /* Team Members */
    .team .col-md-4 {
        margin-bottom: 2rem;
        text-align: center;
    }
    
    /* Services Grid */
    .services .col-md-6 {
        margin-bottom: 2rem;
    }
}

/* Medium Devices (tablets, 768px and up) */
@media (min-width: 768px) and (max-width: 991.98px) {
    /* Hero Section */
    #hero {
        min-height: 90vh;
    }
    
    /* Grid Adjustments */
    .row .col-md-4,
    .row .col-md-6 {
        margin-bottom: 2rem;
    }
    
    /* Navigation */
    .navbar-nav .nav-link {
        padding: 0.5rem 1rem;
    }
    
    /* Cards */
    .card-body {
        padding: 1.75rem;
    }
    
    /* Contact Info */
    .contact-info {
        margin-top: 1rem;
    }
    
    /* Footer adjustments */
    footer .row {
        text-align: center;
    }
    
    footer .col-lg-4 {
        margin-bottom: 2rem;
    }
}

/* Large Devices (desktops, 993px and up) */
@media (min-width: 992px) and (max-width: 1199.98px) {
    /* Container max-width adjustments */
    .container {
        max-width: 960px;
    }
    
    /* Hero Section */
    #hero {
        min-height: 95vh;
    }
    
    /* Typography fine-tuning */
    h1 {
        font-size: 2.79rem;
    }
    
    h2 {
        font-size: 2.27rem;
    }
    
    /* Card spacing */
    .row .col-lg-4,
    .row .col-lg-3 {
        margin-bottom: 2rem;
    }
    
    /* Services layout */
    .services .col-lg-4 {
        margin-bottom: 2rem;
    }
    
    /* Team grid */
    .team .col-lg-2 {
        margin-bottom: 2rem;
    }
}

/* Extra Large Devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
    /* Container max-width */
    .container {
        max-width: 1140px;
    }
    
    /* Hero Section */
    #hero {
        min-height: 100vh;
    }
    
    /* Optimal typography */
    h1 {
        font-size: 3rem;
    }
    
    h2 {
        font-size: 2.60rem;
    }
    
    /* Card optimal sizing */
    .card-body {
        padding: 2.5rem;
    }
    
    /* Services layout optimization */
    .services .row .col-lg-4 {
        margin-bottom: 3rem;
    }
    
    /* Team layout */
    .team .col-lg-2 {
        margin-bottom: 2rem;
    }
    
    /* Gallery spacing */
    #gallery .col-lg-3 {
        padding: 0.25rem;
    }
}

/* Ultra Wide Screens (1400px and up) */
@media (min-width: 1400px) {
    .container {
        max-width: 1320px;
    }
    
    /* Enhanced typography for large screens */
    h1 {
        font-size: 3.52rem;
    }
    
    h2 {
        font-size: 2.87rem;
    }
    
    /* Increased section padding */
    section {
        padding: 6rem 0;
    }
    
    /* Hero adjustments */
    #hero {
        min-height: 100vh;
    }
    
    /* Card enhancements */
    .card {
        border-radius: 16px;
    }
    
    .card-body {
        padding: 3rem;
    }
}

/* Landscape Orientation Adjustments */
@media (orientation: landscape) and (max-height: 600px) {
    #hero {
        min-height: 100vh;
        padding: 1rem 0;
    }
    
    section {
        padding: 3rem 0;
    }
    
    .navbar {
        padding: 0.25rem 0;
    }
}

/* High DPI Displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    /* Optimize for retina displays */
    .card {
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    }
    
    .btn {
        border-width: 1px;
    }
    
    /* Icon sizing for sharp display */
    .fa-3x {
        font-size: 2.5em;
    }
    
    .fa-4x {
        font-size: 3.5em;
    }
}

/* Print Styles */
@media print {
    /* Hide navigation and interactive elements */
    .navbar,
    .btn,
    #gallery,
    footer {
        display: none !important;
    }
    
    /* Optimize typography for print */
    body {
        font-size: 12pt;
        line-height: 1.4;
        color: #000;
        background: #fff;
    }
    
    h1, h2, h3, h4, h5, h6 {
        color: #000;
        page-break-after: avoid;
    }
    
    /* Card styles for print */
    .card {
        border: 1px solid #c8c8c8;
        box-shadow: none;
        page-break-inside: avoid;
        margin-bottom: 1rem;
    }
    
    /* Contact information emphasis */
    .contact-info {
        border: 2px solid #000;
        padding: 1rem;
    }
}

/* Accessibility Enhancements */
@media (prefers-reduced-motion: reduce) {
    /* Remove animations for users who prefer reduced motion */
    .card {
        transition: none;
    }
    
    .btn {
        transition: none;
    }
    
    .fade-in {
        transition: none;
        opacity: 1;
        transform: none;
    }
    
    /* Ensure smooth scrolling is disabled */
    html {
        scroll-behavior: auto;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .card {
        border: 2px solid #000;
    }
    
    .btn-primary {
        background: #000;
        border-color: #000;
    }
    
    .btn-outline-primary {
        border-color: #000;
        color: #000;
    }
}

/* Dark Mode Preference */