/* Responsive CSS - Mobile First Approach */

/* Extra Small devices (portrait phones, less than 576px) */
@media (max-width: 575.98px) {
    /* Typography */
    h1 {
        font-size: 1.81rem;
    }
    
    h2 {
        font-size: 1.64rem;
    }
    
    h3 {
        font-size: 1.39rem;
    }
    
    h4 {
        font-size: 1.28rem;
    }
    
    /* Conservative navbar-brand size on mobile */
    .navbar-brand {
        font-size: 1.15rem;
    }
    
    /* Hero Section */
    #hero {
        min-height: 80vh;
        padding: 2rem 0;
    }
    
    #hero h1 {
        font-size: 1.82rem;
        margin-bottom: 1rem;
    }
    
    #hero h2 {
        font-size: 1.31rem;
        margin-bottom: 1rem;
    }
    
    #hero p {
        font-size: 1rem;
        margin-bottom: 2rem;
    }
    
    /* Button adjustments */
    .btn-lg {
        padding: 0.75rem 1.5rem;
        font-size: 1rem;
    }
    
    /* Card adjustments */
    .card-body {
        padding: 1rem;
    overflow-x: hidden;
}
    
    .card-img-top {
        height: 180px;
    }
    
    /* Section padding */
    section {
        padding: 2rem 0;
    }
    
    /* Services grid */
    #services .col-lg-4 {
        margin-bottom: 1.62rem;
    }
    
    /* Team cards */
    #team .card-img-top {
        height: 200px;
    }
    
    /* Contact form */
    #contacts .form-control {
        padding: 0.75rem;
    }
    
    /* Footer */
    #footer .text-end {
        text-align: left !important;
        margin-top: 1rem;
    }
    
    /* Gallery */
    #gallery .col-md-3 {
        margin-bottom: 1rem;
    }
    
    /* Process section - stack vertically */
    #process .col-md-4,
    #process .col-md-6 {
        margin-bottom: 2rem;
    }
    
    /* Disable animations on mobile for better performance */
    .card:hover {
        transform: none;
    }
    
    .card:hover .card-img-top {
        transform: none;
    }
    
    #gallery img:hover {
        transform: none;
    }
    
    .btn-primary:hover {
        transform: none;
    }
}

/* Small devices (landscape phones, 576px and up) */
@media (min-width: 576px) and (max-width: 767.98px) {
    /* Typography */
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.78rem;
    }
    
    .navbar-brand {
        font-size: 1.26rem;
    }
    
    /* Hero Section */
    #hero h1 {
        font-size: 2rem;
    }
    
    #hero h2 {
        font-size: 1.32rem;
    }
    
    /* Card adjustments */
    .card-img-top {
        height: 200px;
    }
    
    #team .card-img-top {
        height: 220px;
    }
    
    /* Section spacing */
    section {
        padding: 2.5rem 0;
    }
}

/* Medium devices (tablets, 768px and up) */
@media (min-width: 768px) and (max-width: 991.98px) {
    /* Typography */
    .navbar-brand {
        font-size: 1.31rem;
    }
    
    /* Hero Section */
    #hero h1 {
        font-size: 2.24rem;
    }
    
    #hero h2 {
        font-size: 1.43rem;
    }
    
    /* Card heights */
    .card-img-top {
        height: 200px;
    }
    
    #team .card-img-top {
        height: 240px;
    }
    
    /* Services layout */
    #services .col-lg-4:nth-child(odd) {
        margin-bottom: 2rem;
    }
}

/* Large devices (desktops, 992px and up) */
@media (min-width: 992px) and (max-width: 1199.98px) {
    /* Standard desktop styles - mostly inherit from main.css */
    .navbar-brand {
        font-size: 1.36rem;
    }
    
    /* Ensure proper card heights */
    .card-img-top {
        height: 200px;
    }
    
    #team .card-img-top {
        height: 250px;
    }
}

/* Extra large devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
    /* Enhanced spacing for large screens */
    section {
        padding: 4rem 0;
    }
    
    /* Larger hero text */
    #hero h1 {
        font-size: 2.87rem;
    }
    
    #hero h2 {
        font-size: 1.68rem;
    }
    
    /* Card enhancements */
    .card-img-top {
        height: 220px;
    }
    
    #team .card-img-top {
        height: 280px;
    }
    
    /* Enhanced button */
    .btn-lg {
        padding: 1rem 2rem;
        font-size: 1.17rem;
    }
}

/* Landscape orientation adjustments */
@media (orientation: landscape) and (max-height: 500px) {
    #hero {
        min-height: 100vh;
        padding: 1rem 0;
    }
    
    #hero h1 {
        font-size: 1.56rem;
        margin-bottom: 0.73rem;
    }
    
    #hero h2 {
        font-size: 1.29rem;
        margin-bottom: 0.63rem;
    }
    
    #hero p {
        font-size: 0.95rem;
        margin-bottom: 1rem;
    }
}

/* High DPI displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    /* Ensure crisp text rendering */
    body {
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }
}

/* Print styles */
@media print {
    /* Hide navigation and interactive elements */
    #header,
    .btn,
    #footer,
    .breadcrumb-nav {
        display: none !important;
    }
    
    /* Adjust colors for print */
    * {
        color: black !important;
        background: white !important;
    }
    
    /* Ensure proper page breaks */
    section {
        page-break-inside: avoid;
        padding: 1rem 0;
    }
    
    .card {
        border: 1px solid #dadada !important;
        box-shadow: none !important;
    }
}

/* Accessibility - Reduced motion */
@media (prefers-reduced-motion: reduce) {
    /* Disable all animations and transitions on mobile */
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    /* Remove hover effects */
    .card:hover {
        transform: none !important;
        box-shadow: var(--shadow-sm) !important;
    }
    
    .card:hover .card-img-top {
        transform: none !important;
    }
    
    #gallery img:hover {
        transform: none !important;
    }
    
    .btn-primary:hover {
        transform: none !important;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #0b75d0;
        --primary-dark: #0041a1;
        --secondary-color: #11960b;
        --accent-color: #da2200;
        --neutral-color: #1a1919;
        --neutral-dark: #000000;
    }
    
    .card {
        border: 2px solid var(--neutral-color) !important;
    }
    
    .btn {
        border: 2px solid currentColor !important;
    }
}

/* Container max-width adjustments */
@media (min-width: 1400px) {
    .container {
        max-width: 1200px;
    }
}

/* Touch device optimizations */
@media (hover: none) and (pointer: coarse) {
    /* Larger touch targets */
    .btn {
        min-height: 44px;
        min-width: 44px;
    }
    
    .nav-link {
        padding: 1rem !important;
    }
    
    /* Remove hover effects on touch devices */
    .card:hover {
        transform: none;
        box-shadow: var(--shadow-sm);
    }
    
    .btn-primary:hover {
        transform: none;
        background-color: var(--primary-color);
    }
}

/* Dark mode support */

/* Specific mobile menu adjustments - using standard Bootstrap 5 */
@media (max-width: 991.98px) {
    .navbar-collapse {
        background-color: rgba(255, 255, 255, 0.98);
        border-radius: var(--border-radius-md);
        margin-top: 1rem;
        padding: 1rem;
        box-shadow: var(--shadow-md);
    }
    
    .navbar-nav .nav-link {
        padding: 0.75rem 1rem;
        border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    }
    
    .navbar-nav .nav-link:last-child {
        border-bottom: none;
    }
}

/* Additional responsive utilities */
.d-mobile-none {
    display: none;
}

@media (min-width: 768px) {
    .d-mobile-none {
        display: block;
    }
    
    .d-desktop-none {
        display: none;
    }
} 