/* Custom styles for Pa Pa Correa Realtor */

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

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

::-webkit-scrollbar-track {
    background: #050D1A;
}

::-webkit-scrollbar-thumb {
    background: rgba(126, 212, 160, 0.3);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(126, 212, 160, 0.5);
}

/* Selection color */
::selection {
    background: rgba(126, 212, 160, 0.3);
    color: #ffffff;
}

/* Navbar transitions */
#navbar {
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

#navbar.scrolled {
    background: rgba(5, 13, 26, 0.95);
    border-bottom: 1px solid rgba(126, 212, 160, 0.1);
}

/* Service card hover effects */
.service-card {
    transform: translateY(0);
}

.service-card:hover {
    transform: translateY(-4px);
}

/* Testimonial card hover */
.testimonial-card {
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.testimonial-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px -20px rgba(126, 212, 160, 0.1);
}

/* Mobile menu animations */
#mobile-menu {
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

#mobile-menu.open {
    opacity: 1;
    pointer-events: all;
}

#mobile-menu.closed {
    opacity: 0;
    pointer-events: none;
}

/* Menu line animations */
.menu-line {
    display: block;
}

#menu-btn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

#menu-btn.active .menu-line:nth-child(2) {
    opacity: 0;
}

#menu-btn.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
    width: 1.5rem;
}

/* Mobile link animations */
.mobile-link {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

#mobile-menu.open .mobile-link {
    opacity: 1;
    transform: translateY(0);
}

#mobile-menu.open .mobile-link:nth-child(1) { transition-delay: 0.1s; }
#mobile-menu.open .mobile-link:nth-child(2) { transition-delay: 0.15s; }
#mobile-menu.open .mobile-link:nth-child(3) { transition-delay: 0.2s; }
#mobile-menu.open .mobile-link:nth-child(4) { transition-delay: 0.25s; }

/* Scroll reveal animations - progressive enhancement */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* For reduced motion preference */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    
    .service-card,
    .testimonial-card {
        transition: none;
    }
    
    .service-card:hover {
        transform: none;
    }
    
    .testimonial-card:hover {
        transform: none;
    }
}

/* Form select styling */
select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%237ED4A0' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

/* Floating card animation */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

/* Pulse animation for dot */
@keyframes subtle-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Gradient border effect */
.gradient-border {
    position: relative;
}

.gradient-border::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, rgba(126, 212, 160, 0.3), transparent, rgba(126, 212, 160, 0.1));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

/* Image lazy load fade */
img {
    transition: opacity 0.3s ease;
}

/* Ensure contrast for all text elements */
.text-white\/70,
.text-white\/60,
.text-white\/50,
.text-white\/40,
.text-white\/30 {
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* Print styles */
@media print {
    #navbar,
    #mobile-menu,
    .service-card:hover,
    .testimonial-card:hover {
        display: none;
    }
    
    body {
        background: white;
        color: black;
    }
}
