:root {
    /* Color Palette - Premium Real Estate */
    --primary-navy: #0A192F;
    --accent-gold: #C5A059;
    --slate-gray: #4A5568;
    --light-bg: #F7FAFC;
    --white: #FFFFFF;
    --glass-bg: rgba(255, 255, 255, 0.1);
    --glass-border: rgba(255, 255, 255, 0.2);

    /* Typography */
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;

    /* Spacing */
    --section-padding: 100px 20px;
    --border-radius: 12px;
    --transition-smooth: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    background-color: var(--light-bg);
    color: var(--primary-navy);
    line-height: 1.6;
    overflow-x: hidden;
    animation: pageFadeIn 0.6s ease-out both;
}

h1,
h2,
h3 {
    font-family: var(--font-heading);
    font-weight: 700;
}

/* --- Layout Utils --- */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: var(--section-padding);
}

/* --- Animations --- */

/* Keyframes */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes pageFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

@keyframes shimmer {
    0%   { background-position: -200% center; }
    100% { background-position: 200% center; }
}

@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.92); }
    to   { opacity: 1; transform: scale(1); }
}

@keyframes ripple {
    to { transform: scale(4); opacity: 0; }
}

/* ── Scroll progress bar ── */
#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0%;
    background: linear-gradient(90deg, var(--accent-gold), #e8c87a, var(--accent-gold));
    background-size: 200% auto;
    animation: shimmer 2s linear infinite;
    z-index: 9999;
    transition: width 0.1s linear;
    border-radius: 0 2px 2px 0;
}

/* ── Reveal animations (enhanced) ── */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.reveal-up,
.reveal-left,
.reveal-right {
    opacity: 0;
    transition: opacity 0.75s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.75s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal-up    { transform: translateY(50px); }
.reveal-left  { transform: translateX(-50px); }
.reveal-right { transform: translateX(50px); }

.reveal-up.active,
.reveal-left.active,
.reveal-right.active {
    opacity: 1;
    transform: translate(0, 0);
}

/* Stagger delays for sibling reveal elements */
.reveal-up:nth-child(1), .reveal-left:nth-child(1), .reveal-right:nth-child(1) { transition-delay: 0.05s; }
.reveal-up:nth-child(2), .reveal-left:nth-child(2), .reveal-right:nth-child(2) { transition-delay: 0.18s; }
.reveal-up:nth-child(3), .reveal-left:nth-child(3), .reveal-right:nth-child(3) { transition-delay: 0.31s; }

/* Section titles – color sólido */
.section-title h2 {
    color: var(--primary-navy);
}

.testimonials .section-title h2 {
    color: var(--white);
}

/* ── Button ripple effect ── */
.btn {
    position: relative;
    overflow: hidden;
}

.btn .ripple-wave {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.35);
    transform: scale(0);
    animation: ripple 0.55s linear;
    pointer-events: none;
    width: 100px;
    height: 100px;
    margin-top: -50px;
    margin-left: -50px;
}

/* ── Active nav link ── */
.nav-links a.nav-active {
    color: var(--accent-gold) !important;
    opacity: 1 !important;
}

.nav-links a.nav-active::after {
    content: '';
    display: block;
    height: 2px;
    background: var(--accent-gold);
    border-radius: 2px;
    margin-top: 2px;
    animation: scaleIn 0.25s ease;
}



/* --- Navigation --- */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 2000;
    padding: 20px 0;
    transition: background 0.4s ease, padding 0.4s ease, box-shadow 0.4s ease;
    background: transparent;
}

nav.scrolled {
    background: rgba(10, 25, 47, 0.95);
    backdrop-filter: blur(10px);
    padding: 15px 0;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--white);
    text-decoration: none;
    letter-spacing: 1px;
}

.logo span {
    color: var(--accent-gold);
}

.nav-links {
    display: flex;
    gap: 30px;
    list-style: none;
}

.nav-links a {
    color: var(--white);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition-smooth);
    opacity: 0.8;
}

.nav-links a:hover {
    color: var(--accent-gold);
    opacity: 1;
}

/* Menu Toggle */
.menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 6px;
}

.menu-toggle .bar {
    width: 30px;
    height: 3px;
    background-color: var(--white);
    transition: var(--transition-smooth);
}

/* Mobile Menu Animation */
.menu-toggle.is-active .bar:nth-child(2) {
    opacity: 0;
}

.menu-toggle.is-active .bar:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.menu-toggle.is-active .bar:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

/* --- Hero Section --- */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    color: var(--white);
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(10, 25, 47, 0.6), rgba(10, 25, 47, 0.6)), url('src/img/lotes.webp') center/cover no-repeat;
    z-index: -1;
    transform: scale(1.1);
    animation: zoomOut 20s infinite alternate;
}

@keyframes zoomOut {
    from {
        transform: scale(1);
    }

    to {
        transform: scale(1.1);
    }
}

.hero-content {
    max-width: 700px;
    animation: fadeInUp 1s ease-out;
}

.hero h1 {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 20px;
}

.hero h1 span {
    color: var(--accent-gold);
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 35px;
    opacity: 0.9;
}

.btn {
    display: inline-block;
    padding: 16px 32px;
    background-color: var(--accent-gold);
    color: var(--primary-navy);
    text-decoration: none;
    font-weight: 700;
    border-radius: var(--border-radius);
    transition: var(--transition-smooth);
    border: 2px solid var(--accent-gold);
}

.btn:hover {
    background-color: transparent;
    color: var(--accent-gold);
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(197, 160, 89, 0.2);
}

.btn-outline {
    background-color: transparent;
    color: var(--white);
    border: 2px solid var(--white);
    margin-left: 15px;
}

.btn-outline:hover {
    background-color: var(--white);
    color: var(--primary-navy);
}

/* --- Features / Services Section --- */
.section-title {
    text-align: center;
    margin-bottom: 60px;
}

.section-title h2 {
    font-size: 2.5rem;
    margin-bottom: 15px;
}

.section-title .underline {
    width: 80px;
    height: 4px;
    background: var(--accent-gold);
    margin: 0 auto;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.card {
    background: var(--white);
    padding: 40px;
    border-radius: var(--border-radius);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    transition: var(--transition-smooth);
    border-bottom: 4px solid transparent;
}

.card:hover {
    transform: translateY(-10px);
    border-bottom: 4px solid var(--accent-gold);
}

.card i {
    font-size: 2.5rem;
    color: var(--accent-gold);
    margin-bottom: 20px;
    display: block;
}

.card h3 {
    margin-bottom: 15px;
}

/* --- Gallery Section --- */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.gallery-item {
    position: relative;
    border-radius: var(--border-radius);
    overflow: hidden;
    height: 300px;
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-smooth);
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 25, 47, 0.7);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: var(--white);
    opacity: 0;
    transition: var(--transition-smooth);
    padding: 20px;
    text-align: center;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.gallery-overlay h3 {
    margin-bottom: 10px;
    font-size: 1.5rem;
}

.gallery-overlay .btn {
    padding: 10px 20px;
    font-size: 0.9rem;
}

/* --- Testimonials Carousel --- */
.testimonials {
    background-color: var(--primary-navy);
    color: var(--white);
}

.testimonials-carousel {
    display: flex;
    align-items: center;
    gap: 16px;
}

.carousel-track-wrapper {
    overflow: hidden;
    flex: 1;
}

.carousel-track {
    display: flex;
    gap: 24px;
    transition: transform 0.45s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}

.testimonial-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    padding: 36px 32px;
    border-radius: var(--border-radius);
    text-align: center;
    flex: 0 0 calc(33.333% - 16px);
    min-width: 0;
    transition: border-color 0.3s;
}

.testimonial-card:hover {
    border-color: rgba(197, 160, 89, 0.4);
}

.testimonial-card i {
    font-size: 1.6rem;
    color: var(--accent-gold);
    margin-bottom: 18px;
    display: block;
}

.testimonial-card p {
    font-size: 1rem;
    font-style: italic;
    margin-bottom: 20px;
    line-height: 1.7;
    opacity: 0.9;
}

.testimonial-card h4 {
    color: var(--accent-gold);
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* Arrow buttons */
.carousel-btn {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--white);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: var(--transition-smooth);
    font-size: 0.9rem;
}

.carousel-btn:hover {
    background: var(--accent-gold);
    border-color: var(--accent-gold);
    color: var(--primary-navy);
    transform: scale(1.08);
}

.carousel-btn:disabled {
    opacity: 0.3;
    cursor: default;
    transform: none;
}

/* Dots */
.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 28px;
}

.carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: var(--transition-smooth);
    border: none;
    padding: 0;
}

.carousel-dot.active {
    background: var(--accent-gold);
    width: 24px;
    border-radius: 4px;
}



/* --- Contact & Footer --- */
.contact-footer {
    padding-top: 100px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 50px;
    margin-bottom: 50px;
}

.footer-logo {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary-navy);
    text-decoration: none;
    margin-bottom: 20px;
    display: block;
}

.footer-logo span {
    color: var(--accent-gold);
}

.footer-links h4 {
    margin-bottom: 20px;
    position: relative;
}

.footer-links h4::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 30px;
    height: 2px;
    background: var(--accent-gold);
}

.footer-links ul {
    list-style: none;
}

.footer-links ul li {
    margin-bottom: 12px;
}

.footer-links ul li a {
    text-decoration: none;
    color: var(--slate-gray);
    transition: var(--transition-smooth);
}

.footer-links ul li a:hover {
    color: var(--accent-gold);
    padding-left: 5px;
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-links a {
    width: 40px;
    height: 40px;
    background: var(--primary-navy);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: var(--transition-smooth);
    text-decoration: none;
}

.social-links a:hover {
    background: var(--accent-gold);
    transform: translateY(-3px);
}

.footer-bottom {
    border-top: 1px solid #e2e8f0;
    padding-top: 30px;
    text-align: center;
    color: var(--slate-gray);
    font-size: 0.9rem;
}

/* --- Responsive --- */
@media (max-width: 992px) {
    .hero h1 {
        font-size: 3rem;
    }

    /* Carousel: 2 cards en tablet */
    .testimonial-card {
        flex: 0 0 calc(50% - 12px);
    }
}

@media (max-width: 768px) {
    /* Evita que nav cree un nuevo bloque contenedor para position:fixed */
    nav.scrolled {
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .menu-toggle {
        display: flex;
        z-index: 2100;
        position: relative;
        gap: 5px;
    }

    .menu-toggle .bar {
        width: 22px;
        height: 2px;
    }

    .menu-toggle.is-active .bar:nth-child(1) {
        transform: translateY(7px) rotate(45deg);
    }

    .menu-toggle.is-active .bar:nth-child(3) {
        transform: translateY(-7px) rotate(-45deg);
    }

    .nav-links {
        position: fixed;
        top: -100%;
        left: 0;
        flex-direction: column;
        background: rgba(10, 25, 47, 0.97);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        width: 100%;
        height: auto;
        padding: 80px 30px 30px;
        text-align: left;
        transition: top 0.35s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
        justify-content: flex-start;
        z-index: 2000;
        gap: 0;
        border-bottom: 1px solid rgba(197, 160, 89, 0.2);
    }

    .nav-links.active {
        top: 0;
        left: 0;
    }

    .nav-links li {
        margin: 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    }

    .nav-links li:last-child {
        border-bottom: none;
    }

    .nav-links a {
        font-size: 0.95rem;
        font-weight: 500;
        color: rgba(255, 255, 255, 0.85);
        opacity: 1;
        display: block;
        padding: 13px 0;
        letter-spacing: 0.5px;
        transition: var(--transition-smooth);
    }

    .nav-links a:hover {
        color: var(--accent-gold);
        padding-left: 6px;
    }

    .hero h1 {
        font-size: 2.2rem;
    }

    .hero-btns {
        display: flex;
        flex-direction: column;
        gap: 15px;
    }

    .btn-outline {
        margin-left: 0;
    }

    section {
        padding: 60px 20px;
    }

    .gallery-grid {
        grid-template-columns: 1fr;
    }

    .services-grid {
        grid-template-columns: 1fr !important;
    }

    /* Carousel: 1 card en móvil */
    .testimonial-card {
        flex: 0 0 100%;
    }

    .carousel-btn {
        width: 36px;
        height: 36px;
        font-size: 0.8rem;
    }

    .testimonials-carousel {
        gap: 8px;
    }
}

/* --- Botón Flotante WhatsApp --- */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background-color: #25D366;
    color: #FFF;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 35px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    z-index: 9999;
    text-decoration: none;
    transition: transform 0.3s ease, background-color 0.3s ease;
    animation: floatBounce 2s infinite ease-in-out;
}

.whatsapp-float:hover {
    background-color: #1EBE5D;
    transform: scale(1.1);
    animation: none; /* Se detiene al hacer hover */
}

/* Animación sutil de rebote/pulso */
@keyframes floatBounce {
    0%, 100% {
        transform: translateY(0) scale(1);
        box-shadow: 0 4px 10px rgba(37, 211, 102, 0.5);
    }
    50% {
        transform: translateY(-8px) scale(1.05);
        box-shadow: 0 10px 20px rgba(37, 211, 102, 0.7);
    }
}

/* Ajuste WhatsApp en móviles */
@media (max-width: 768px) {
    .whatsapp-float {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
        font-size: 28px;
    }
}