/* Ryan Casuso Realtor — Custom Styles */

/* Base reset and typography refinements */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    margin: 0;
    overflow-x: hidden;
}

/* Ensure all links are visible */
a {
    text-decoration: none;
}

/* Selection color */
::selection {
    background: #f76e3a;
    color: #fff;
}

/* Smooth image rendering */
img {
    -webkit-font-smoothing: antialiased;
}

/* Custom focus styles for accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid #f76e3a;
    outline-offset: 2px;
}

/* Hide mobile menu by default */
#mobileMenu {
    display: none;
}

#mobileMenu.open {
    display: flex;
}

/* Tablet and up: always show mobile menu overlay when open */
@media (min-width: 768px) {
    #mobileMenu {
        display: none !important;
    }
}

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

    .hero-bg {
        background-attachment: scroll !important;
    }

    .cta-pulse {
        animation: none !important;
    }
}

/* Print styles */
@media print {
    nav,
    #mobileMenu,
    .cta-pulse {
        display: none !important;
    }

    body {
        color: #000;
        background: #fff;
    }

    .hero-bg {
        background: #1a1a1a !important;
    }
}

/* High contrast mode support */
@media (forced-colors: active) {
    .service-card,
    .testimonial-card {
        border: 1px solid CanvasText;
    }

    .img-reveal::after {
        display: none;
    }
}

/* Ensure adequate contrast for all text elements */
.text-charcoal-600 {
    color: #4a4a4a;
}

.text-charcoal-700 {
    color: #3d3d3d;
}

.text-charcoal-800 {
    color: #2d2d2d;
}

.bg-charcoal-900 {
    background-color: #1a1a1a;
}

/* Ensure buttons have proper contrast */
button,
[type='button'],
[type='submit'] {
    cursor: pointer;
}

/* Improve touch targets on mobile */
@media (max-width: 767px) {
    a,
    button {
        min-height: 44px;
        min-width: 44px;
    }
}

/* Improve readability on small screens */
@media (max-width: 640px) {
    h1 {
        font-size: 2.25rem;
        line-height: 1.1;
    }

    h2 {
        font-size: 1.75rem;
        line-height: 1.2;
    }

    p {
        font-size: 1rem;
        line-height: 1.6;
    }
}

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