/* Responsive Design - Mobile First Approach */

/* Extra Small Devices (phones, less than 576px) */
@media (max-width: 575.98px) {
    /* Typography adjustments for mobile */
    h1, .display-4 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.75rem;
    }
    
    h3, .h5 {
        font-size: 1.1rem;
    }
    
    p.lead {
        font-size: 1rem;
    }
    
    /* Hero section mobile */
    #hero {
        padding: 4rem 0;
        text-align: center;
    }
    
    #hero .display-4 {
        font-size: 1.75rem;
        margin-bottom: 1rem;
    }
    
    /* Disable animations on mobile for better performance */
    #hero::before {
        display: none;
    }
    
    /* Section spacing for mobile */
    section {
        padding: 3rem 0;
    }
    
    /* Card adjustments */
    .card {
        margin-bottom: 1.5rem;
    }
    
    .card-body {
        padding: 1.5rem;
    overflow-x: hidden;
}
    
    /* Button adjustments */
    .btn {
        width: 100%;
        margin-bottom: 0.5rem;
    }
    
    /* Services grid on mobile */
    #services .col-md-6:not(:last-child) {
        margin-bottom: 2rem;
    }
    
    /* Features icons smaller on mobile */
    #features i {
        font-size: 2.5rem !important;
    }
    
    /* Price plan cards */
    #priceplan .card.border-primary {
        transform: none;
        margin-bottom: 2rem;
    }
    
    #priceplan .card.border-primary::before {
        top: -10px;
        font-size: 0.75rem;
        padding: 3px 15px;
    }
    
    /* Team section mobile layout */
    #team .col-md-6 {
        margin-bottom: 2rem;
    }
    
    /* Process section mobile */
    #process .col-md-6 {
        margin-bottom: 2rem;
        text-align: center;
    }
    
    /* Contact form mobile */
    #contacts .col-lg-8 {
        margin-bottom: 2rem;
    }
    
    /* Footer mobile */
    #footer .col-lg-4 {
        text-align: center;
        margin-bottom: 2rem;
    }
    
    /* Gallery mobile - single column */
    #gallery .col-md-4 {
        margin-bottom: 1rem;
    }
    
    /* Additional pages mobile */
    .display-4.fw-bold {
        font-size: 2rem;
    }
}

/* Small Devices (landscape phones, 576px and up) */
@media (min-width: 576px) and (max-width: 767.98px) {
    /* Hero adjustments */
    #hero {
        padding: 5rem 0;
    }
    
    #hero .display-4 {
        font-size: 2.25rem;
    }
    
    /* Section spacing */
    section {
        padding: 4rem 0;
    }
    
    /* Services - 2 columns on small tablets */
    #services .row .col-md-6:nth-child(odd) {
        padding-right: 0.75rem;
    }
    
    #services .row .col-md-6:nth-child(even) {
        padding-left: 0.75rem;
    }
    
    /* Features - 2 columns */
    #features .col-lg-3 {
        margin-bottom: 2rem;
    }
    
    /* Price plan - stack cards */
    #priceplan .col-lg-4 {
        margin-bottom: 2rem;
    }
    
    /* Team - 2 columns */
    #team .col-lg-2 {
        margin-bottom: 2rem;
    }
    
    /* Process - 2 columns */
    #process .col-lg-2 {
        margin-bottom: 2rem;
    }
}

/* Medium Devices (tablets, 768px and up) */
@media (min-width: 768px) and (max-width: 991.98px) {
    /* Hero section */
    #hero .display-4 {
        font-size: 2.5rem;
    }
    
    /* Services - 2 columns */
    #services .col-lg-4:nth-child(3n) {
        margin-top: 2rem;
    }
    
    /* Features - 2 columns */
    #features .col-lg-3:nth-child(3n),
    #features .col-lg-3:nth-child(4n) {
        margin-top: 2rem;
    }
    
    /* Team - 3 columns, adjust last 2 */
    #team .col-lg-2:nth-child(4n),
    #team .col-lg-2:nth-child(5n) {
        margin-top: 2rem;
    }
    
    /* Process - 3 columns */
    #process .col-lg-2:nth-child(4n),
    #process .col-lg-2:nth-child(5n) {
        margin-top: 2rem;
    }
    
    /* Gallery - 2 columns */
    #gallery .col-md-4:nth-child(3n) {
        margin-top: 1rem;
    }
}

/* Large Devices (desktops, 992px and up) */
@media (min-width: 992px) and (max-width: 1199.98px) {
    /* Services - 3 columns, perfect fit */
    #services .col-lg-4 {
        margin-bottom: 2rem;
    }
    
    /* Team - 5 columns, adjust spacing */
    #team .col-lg-2 {
        flex: 0 0 20%;
        max-width: 20%;
    }
    
    /* Process - 5 columns */
    #process .col-lg-2 {
        flex: 0 0 20%;
        max-width: 20%;
    }
}

/* Extra Large Devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
    /* Container max-width adjustment for very large screens */
    .container {
        max-width: 1200px;
    }
    
    /* Hero section enhanced */
    #hero .display-4 {
        font-size: 3rem;
    }
    
    /* Enhanced card hover effects on larger screens */
    .card:hover {
        transform: translateY(-8px);
    }
    
    /* Enhanced button hover effects */
    .btn-primary:hover,
    .btn-outline-primary:hover {
        transform: translateY(-3px);
    }
}

/* Landscape Orientation */
@media (orientation: landscape) and (max-height: 600px) {
    /* Reduce hero height on landscape mobile */
    #hero {
        min-height: 100vh;
        padding: 2rem 0;
    }
    
    /* Reduce section padding */
    section {
        padding: 2rem 0;
    }
    
    /* Smaller navbar */
    .navbar-brand {
        font-size: 1.1rem !important;
    }
    
    .navbar-nav .nav-link {
        font-size: 0.9rem;
    }
}

/* Print Styles */
@media print {
    /* Remove animations and transitions */
    * {
        animation: none !important;
        transition: none !important;
    }
    
    /* Hide navigation and interactive elements */
    #header,
    .btn,
    #footer {
        display: none !important;
    }
    
    /* Optimize for print */
    body {
        font-size: 12pt;
        line-height: 1.4;
        color: #000;
    }
    
    /* Ensure images fit page */
    img {
        max-width: 100% !important;
        height: auto !important;
    }
    
    /* Page breaks */
    section {
        page-break-inside: avoid;
        break-inside: avoid;
    }
    
    h1, h2, h3, h4, h5, h6 {
        page-break-after: avoid;
        break-after: avoid;
    }
}

/* High DPI/Retina Display Support */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    /* Sharper borders and shadows for high DPI */
    .card {
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    }
    
    .card:hover {
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
    }
}

/* Accessibility - Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    /* Remove all animations and transitions */
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    /* Remove hover transforms */
    .card:hover,
    .btn:hover,
    #team img:hover,
    #gallery img:hover {
        transform: none !important;
    }
}

/* Dark Mode Support */

/* Container Breakpoint Adjustments */
@media (min-width: 1400px) {
    .container {
        max-width: 1320px;
    }
}

/* Focus States for Better Accessibility */
@media (any-hover: hover) {
    .btn:focus,
    .form-control:focus,
    .nav-link:focus {
        outline: 2px solid var(--primary-color);
        outline-offset: 2px;
    }
}

/* Touch Device Optimizations */
@media (any-pointer: coarse) {
    /* Larger touch targets */
    .btn {
        min-height: 44px;
        min-width: 44px;
    }
    
    .nav-link {
        padding: 1rem 1.5rem;
    }
    
    /* Remove hover effects on touch devices */
    .card:hover,
    .btn:hover {
        transform: none;
    }
} 