/* ===================================================================
   Casa Verde - Estilos Principales
   Diseño ecológico, moderno y optimizado para retina
   =================================================================== */

:root {
    --primary-green: #245A34;
    --primary-green-hover: #1c4729;
    --forest-dark: #12281b;
    --sage-light: #e8f3ec;
    --accent-gold: #c79848;
    --accent-gold-hover: #b38437;
    --earth-warm: #8d7053;
    --bg-creamy: #f9fbf8;
    --bg-surface: #ffffff;
    --text-primary: #1f2a24;
    --text-muted: #5d6d63;
    --border-color: #e2ebe4;
    --font-heading: 'Cormorant Garamond', Georgia, serif;
    --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    --shadow-soft: 0 10px 30px rgba(18, 40, 27, 0.06);
    --shadow-hover: 0 16px 40px rgba(18, 40, 27, 0.12);
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-full: 9999px;
    --transition-smooth: all 0.35s cubic-bezier(0.25, 1, 0.5, 1);
}

/* Reseteo básico y tipografía */
body {
    font-family: var(--font-sans);
    color: var(--text-primary);
    background-color: var(--bg-creamy);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6, .font-serif {
    font-family: var(--font-heading);
    letter-spacing: -0.01em;
}

/* Colores utilitarios */
.text-primary-green { color: var(--primary-green) !important; }
.bg-primary-green { background-color: var(--primary-green) !important; }
.bg-dark-forest { background-color: var(--forest-dark) !important; }
.text-accent { color: var(--accent-gold) !important; }
.bg-accent { background-color: var(--accent-gold) !important; }
.bg-sage { background-color: var(--sage-light) !important; }
.border-accent { border-color: var(--accent-gold) !important; }
.border-white-10 { border-color: rgba(255, 255, 255, 0.1) !important; }
.text-light-50 { color: rgba(255, 255, 255, 0.65) !important; }

/* Barra superior */
.eco-topbar {
    background-color: #0d1e14;
    letter-spacing: 0.02em;
}
.hover-accent:hover {
    color: var(--accent-gold) !important;
}

/* Encabezado y Barra de Navegación */
.navbar-header {
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    background-color: rgba(255, 255, 255, 0.94);
    transition: var(--transition-smooth);
}
.navbar-header.scrolled {
    padding-top: 4px;
    padding-bottom: 4px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08) !important;
}

.brand-icon-wrapper {
    width: 44px;
    height: 44px;
    background: #edf7ef;
    border-radius: 50%;
}
.brand-icon {
    font-size: 1.55rem;
}
.brand-title {
    font-size: 1.35rem;
    font-family: var(--font-heading);
    letter-spacing: 0.04em;
}

.navbar .nav-link {
    color: #2b3930;
    font-size: 0.95rem;
    font-weight: 500;
    position: relative;
    transition: var(--transition-smooth);
}
.navbar .nav-link:hover,
.navbar .nav-link.active {
    color: var(--primary-green);
}
.navbar .nav-link::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 1rem;
    right: 1rem;
    height: 2px;
    background: var(--accent-gold);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}
.navbar .nav-link:hover::after,
.navbar .nav-link.active::after {
    transform: scaleX(1);
}

/* Botones con estilo orgánico */
.btn-primary-green {
    background-color: var(--primary-green);
    border-color: var(--primary-green);
    color: #ffffff;
    transition: var(--transition-smooth);
}
.btn-primary-green:hover,
.btn-primary-green:focus {
    background-color: var(--primary-green-hover);
    border-color: var(--primary-green-hover);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 8px 18px rgba(36, 90, 52, 0.28);
}

.btn-accent {
    background-color: var(--accent-gold);
    border-color: var(--accent-gold);
    color: #ffffff;
    transition: var(--transition-smooth);
}
.btn-accent:hover {
    background-color: var(--accent-gold-hover);
    border-color: var(--accent-gold-hover);
    color: #ffffff;
    transform: translateY(-2px);
}

/* Sección Hero con Parallax */
.hero-section {
    position: relative;
    min-height: 88vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, rgba(14, 34, 21, 0.85) 0%, rgba(20, 48, 30, 0.65) 100%),
                url('https://images.unsplash.com/photo-1500937386664-56d1dfef3854?auto=format&fit=crop&w=1920&q=80') center center / cover no-repeat;
    background-attachment: fixed;
    color: #ffffff;
    padding: 100px 0;
}
@media (max-width: 991px) {
    .hero-section {
        background-attachment: scroll; /* Suavidad en dispositivos móviles */
        min-height: 75vh;
        padding: 60px 0;
    }
}

.hero-title {
    font-size: clamp(2.4rem, 5vw, 4.2rem);
    line-height: 1.12;
    font-weight: 700;
}
.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: rgba(255, 255, 255, 0.9);
}

/* Parallax Banner de Cita / Manifiesto */
.parallax-banner {
    position: relative;
    background: linear-gradient(rgba(14, 30, 20, 0.82), rgba(14, 30, 20, 0.82)),
                url('https://images.unsplash.com/photo-1595974482597-4b8da8879bc5?auto=format&fit=crop&w=1920&q=80') center center / cover no-repeat;
    background-attachment: fixed;
    color: #ffffff;
    padding: 110px 0;
}
@media (max-width: 991px) {
    .parallax-banner {
        background-attachment: scroll;
        padding: 70px 0;
    }
}

/* Tarjetas de Métricas / Impacto */
.impact-badge-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 24px 20px;
    box-shadow: var(--shadow-soft);
    transition: var(--transition-smooth);
}
.impact-badge-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
    border-color: rgba(36, 90, 52, 0.3);
}

/* Tarjetas de Productos & Cosecha */
.product-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: var(--transition-smooth);
    box-shadow: var(--shadow-soft);
    display: flex;
    flex-direction: column;
    height: 100%;
}
.product-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
    border-color: #b9d8bf;
}
.product-img-wrapper {
    position: relative;
    width: 100%;
    height: 240px;
    overflow: hidden;
    background-color: #f0f4f1;
}
.product-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}
.product-card:hover .product-img-wrapper img {
    transform: scale(1.08);
}
.product-badge-fresh {
    position: absolute;
    top: 12px;
    left: 12px;
    background: rgba(36, 90, 52, 0.9);
    backdrop-filter: blur(4px);
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: var(--radius-full);
}

/* Tarjetas de Proyectos Ecológicos */
.eco-project-card {
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    background: #ffffff;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
    transition: var(--transition-smooth);
}
.eco-project-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}
.eco-project-img {
    height: 260px;
    object-fit: cover;
    width: 100%;
}

/* Filtros de Productos */
.filter-btn-group .btn {
    border-radius: var(--radius-full);
    padding: 8px 20px;
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--text-muted);
    border: 1px solid var(--border-color);
    background: #ffffff;
    transition: var(--transition-smooth);
}
.filter-btn-group .btn.active,
.filter-btn-group .btn:hover {
    background-color: var(--primary-green);
    border-color: var(--primary-green);
    color: #ffffff;
}

/* Sección de Testimonios */
.testimonial-card {
    background: #ffffff;
    border-radius: var(--radius-md);
    padding: 30px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
    position: relative;
}
.testimonial-quote-icon {
    font-size: 2.5rem;
    color: #d1e3d6;
    line-height: 1;
}

/* Tarjeta del Boletín */
.newsletter-card {
    background: linear-gradient(135deg, #ffffff 0%, #f4fbf6 100%);
    border: 1px solid #c9e3cf;
}

/* Formulario de Contacto Ajax */
.contact-card {
    background: #ffffff;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--border-color);
    padding: 40px;
}
@media (max-width: 767px) {
    .contact-card {
        padding: 24px;
    }
}
.form-control, .form-select {
    border: 1px solid #d4ded7;
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    font-size: 0.95rem;
    transition: var(--transition-smooth);
}
.form-control:focus, .form-select:focus {
    border-color: var(--primary-green);
    box-shadow: 0 0 0 3px rgba(36, 90, 52, 0.15);
}

/* Honeypot anti-spam oculto */
.eco-hp-field {
    display: none !important;
    visibility: hidden !important;
    position: absolute !important;
    left: -9999px !important;
}

/* Pie de página */
.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    transition: var(--transition-smooth);
}
.footer-links a:hover {
    color: var(--accent-gold);
    padding-left: 4px;
}
.social-btn {
    width: 38px;
    height: 38px;
    background: rgba(255, 255, 255, 0.08);
    transition: var(--transition-smooth);
    text-decoration: none;
}
.social-btn:hover {
    background: var(--accent-gold);
    transform: translateY(-3px);
}

/* Botón Flotante de WhatsApp */
.whatsapp-float {
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 55px;
    height: 55px;
    background-color: #25D366;
    color: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    z-index: 1000;
    text-decoration: none;
    transition: var(--transition-smooth);
}
.whatsapp-float:hover {
    color: #ffffff;
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 10px 25px rgba(37, 211, 102, 0.45);
}

/* Botón Scroll to Top */
.scroll-top-btn {
    position: fixed;
    bottom: 90px;
    right: 27px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background-color: var(--forest-dark);
    color: #ffffff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    cursor: pointer;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-smooth);
}
.scroll-top-btn.show {
    opacity: 1;
    visibility: visible;
}
.scroll-top-btn:hover {
    background-color: var(--primary-green);
    transform: translateY(-3px);
}
