/* ============================================
   CLEMENTINA CALVO SITGES — REAL ESTATE
   Custom Styles
   ============================================ */

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

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

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

::-webkit-scrollbar-thumb {
    background: #1E4D65;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #3BA87A;
}

/* Selection */
::selection {
    background: rgba(94, 196, 148, 0.3);
    color: #ffffff;
}

/* ============================================
   NAVIGATION
   ============================================ */
#navbar {
    backdrop-filter: blur(0px);
    transition: backdrop-filter 0.5s ease, background 0.5s ease, box-shadow 0.5s ease;
}

#navbar.scrolled {
    backdrop-filter: blur(20px);
    background: rgba(7, 21, 32, 0.9);
    box-shadow: 0 1px 0 rgba(94, 196, 148, 0.1);
}

/* Mobile menu animation */
#mobile-menu.open {
    opacity: 1;
    pointer-events: all;
}

.menu-line {
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.27, 1.55);
}

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

#menu-toggle.active .menu-line:nth-child(2) {
    opacity: 0;
    transform: translateX(10px);
}

#menu-toggle.active .menu-line:nth-child(3) {
    width: 24px;
    transform: rotate(-45deg) translate(3px, -3px);
}

.mobile-link {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease, color 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; }
#mobile-menu.open .mobile-link:nth-child(5) { transition-delay: 0.3s; }

/* ============================================
   HERO ANIMATIONS
   ============================================ */
.hero-subtitle {
    animation: fadeUp 0.8s ease forwards;
    opacity: 0;
    animation-delay: 0.2s;
}

.hero-headline {
    opacity: 0;
    animation: fadeUp 1s ease forwards;
    animation-delay: 0.4s;
}

.hero-desc {
    opacity: 0;
    animation: fadeUp 1s ease forwards;
    animation-delay: 0.8s;
}

.hero-cta {
    opacity: 0;
    animation: fadeUp 1s ease forwards;
    animation-delay: 1s;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   SECTION LABELS
   ============================================ */
.section-label {
    display: flex;
    align-items: center;
}

/* ============================================
   SERVICE CARDS
   ============================================ */
.service-card {
    transform: translateY(0);
    transition: transform 0.5s ease, border-color 0.5s ease, box-shadow 0.5s ease;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

/* ============================================
   TESTIMONIAL CARDS
   ============================================ */
.testimonial-card {
    transform: translateY(0);
    transition: transform 0.5s ease, border-color 0.5s ease, box-shadow 0.5s ease;
}

.testimonial-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.3);
}

/* ============================================
   SCROLL REVEAL ANIMATIONS
   ============================================ */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* ============================================
   PARALLAX-LIKE EFFECTS
   ============================================ */
.about-image img {
    transition: transform 0.7s ease;
}

.about-image:hover img {
    transform: scale(1.03);
}

/* ============================================
   IMAGE HOVER ZOOM
   ============================================ */
.overflow-hidden img {
    transition: transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ============================================
   FORM STYLES
   ============================================ */
select option {
    background: #0F2B3C;
    color: #ffffff;
}

/* ============================================
   RESPONSIVE ADJUSTMENTS
   ============================================ */
@media (max-width: 768px) {
    .hero-headline {
        font-size: 2.5rem;
    }
    
    .hero-headline br {
        display: none;
    }
    
    #about, #services, #areas, #testimonials, #contact {
        padding-top: 80px;
        padding-bottom: 80px;
    }
}

@media (min-width: 769px) and (max-width: 1023px) {
    .hero-headline {
        font-size: 4rem;
    }
}

/* ============================================
   FOCUS VISIBLE
   ============================================ */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 2px solid #5EC494;
    outline-offset: 2px;
}

/* ============================================
   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;
    }
    
    .reveal {
        opacity: 1;
        transform: none;
    }
}
