/* Custom styles for Construction Remodeling Painting */

/* Smooth scroll behavior */
html {
    scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #061020;
}

::-webkit-scrollbar-thumb {
    background: #285395;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #e6b800;
}

/* Selection color */
::selection {
    background: #e6b800;
    color: #061020;
}

/* Focus visible styles */
:focus-visible {
    outline: 2px solid #e6b800;
    outline-offset: 2px;
}

/* Ensure images don't overflow */
img {
    max-width: 100%;
    height: auto;
}

/* Print styles */
@media print {
    nav, .cta-button, button {
        display: none;
    }
    
    body {
        background: white;
        color: black;
    }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .service-card {
        border: 2px solid #e6b800;
    }
    
    .testimonial-card {
        border: 2px solid #e6b800;
    }
}

/* Landscape orientation on mobile */
@media (max-height: 500px) and (orientation: landscape) {
    .hero-split {
        min-height: auto;
    }
}

/* Touch device optimizations */
@media (hover: none) {
    .service-card:hover {
        transform: none;
    }
    
    .gallery-item:hover img {
        transform: none;
    }
    
    .gallery-item:hover .gallery-overlay {
        opacity: 0;
    }
}

/* Tablet landscape */
@media (min-width: 768px) and (max-width: 1023px) and (orientation: landscape) {
    .hero-split {
        grid-template-columns: 1fr 1fr;
    }
}

/* Large screens */
@media (min-width: 1920px) {
    .max-w-7xl {
        max-width: 80rem;
    }
}

/* Ensure proper rendering on all devices */
@media all {
    .service-card,
    .testimonial-card,
    .gallery-item {
        contain: layout style;
    }
}
