/* Global Styles */
:root {
    --primary-green: #2E7D32;
    --primary-dark: #1b5e20;
    --primary-light: #4caf50;
    --accent-lime: #66bb6a;
    /* Brighter accent */
    --white: #ffffff;
    --light-gray: #f5f5f5;
    --dark-text: #333333;
    --mid-gray: #666666;
    --box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Montserrat', sans-serif;
    color: var(--dark-text);
    line-height: 1.6;
    background-color: var(--white);
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

h1,
h2,
h3,
h4 {
    font-weight: 700;
    line-height: 1.2;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 6px;
    font-weight: 600;
    text-transform: uppercase;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    text-align: center;
}

.btn-primary {
    background-color: var(--accent-lime);
    /* Vibrant green CTA */
    color: var(--primary-dark);
    box-shadow: 0 4px 15px rgba(102, 187, 106, 0.4);
}

.btn-primary:hover {
    background-color: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 187, 106, 0.6);
}

.btn-full {
    width: 100%;
    background-color: var(--accent-lime);
    color: var(--primary-dark);
    font-size: 1rem;
}

.btn-full:hover {
    background-color: var(--primary-light);
}

/* Header */
#main-header {
    background: var(--white);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    height: 150px;
    display: flex;
    align-items: center;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.container.header-content {
    max-width: 100%;
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-container {
    display: flex;
    flex-direction: row;
    align-items: center;
}

.logo-link {
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
    height: 150px;
}

.logo-text-group {
    display: flex;
    white-space: nowrap;
    color: var(--primary-green);
    margin-left: 180px; /* Margen base para pantallas muy grandes */
    transition: margin-left 0.3s ease;
}

/* Responsividad para el Header */
@media (max-width: 1600px) {
    .logo-text-group {
        margin-left: 100px; /* Reducimos margen en laptops grandes */
    }
}

@media (max-width: 1400px) {
    .logo-text-group {
        margin-left: 40px; /* Reducimos más en laptops estándar */
    }
    .logo-full-text {
        font-size: 1.8rem; /* Ajustamos fuente un poco */
    }
}

@media (max-width: 1200px) {
    .container.header-content {
        padding: 0 20px;
    }
    .logo-text-group {
        margin-left: 20px; /* Margen mínimo */
    }
    .logo-full-text {
        font-size: 1.5rem; /* Fuente más compacta */
    }
    .tagline {
        font-size: 0.7rem; /* Reducir tagline */
        padding-right: 10px;
    }
    .header-right {
        gap: 15px;
    }
}

@media (max-width: 992px) {
    .logo-text-group {
        margin-left: 10px;
    }
    .logo-img {
        max-height: 80px;
    }
    .logo-link {
        height: 100px;
    }
    #main-header {
        height: 100px;
    }
    .hero-section {
        margin-top: 100px;
    }
    .container.header-content {
        padding: 0 15px;
    }
}

/* Mejoras para tablet */
@media (max-width: 768px) {
    .logo-full-text {
        font-size: 1.3rem;
    }
}

.logo-full-text {
    font-size: 2.2rem;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.logo-img {
    height: auto;
    max-height: 130px;
    width: auto;
    object-fit: contain;
    filter: brightness(1.02) contrast(1.02);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 30px;
}

.tagline {
    font-size: 0.8rem;
    color: var(--mid-gray);
    font-weight: 600;
    border-right: 1px solid #ddd;
    padding-right: 20px;
    display: none;
    /* Hidden on small screens */
}

@media (min-width: 992px) {
    .tagline {
        display: block;
    }
}

.nav-list {
    display: none;
    /* Hidden on mobile */
    gap: 25px;
}

@media (min-width: 992px) {
    .nav-list {
        display: flex;
    }
}

.nav-list a {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--dark-text);
    position: relative;
    padding-bottom: 5px;
}

.nav-list a.active,
.nav-list a:hover {
    color: var(--primary-green);
}

.nav-list a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-green);
    transition: width 0.3s;
}

.nav-list a:hover::after,
.nav-list a.active::after {
    width: 100%;
}

.menu-toggle {
    display: block;
    font-size: 1.5rem;
    background: none;
    border: none;
    color: var(--primary-green);
    cursor: pointer;
}

@media (min-width: 992px) {
    .menu-toggle {
        display: none;
    }
}

/* Mobile Menu */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1001;
    display: none;
    opacity: 0;
    transition: opacity 0.3s;
}

.mobile-menu {
    position: fixed;
    top: 0;
    right: -300px;
    width: 300px;
    max-width: 85vw;
    height: 100%;
    background: var(--white);
    z-index: 1002;
    padding: 80px 30px 30px;
    transition: right 0.3s cubic-bezier(0.77, 0, 0.175, 1);
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
}

@media (max-width: 480px) {
    .mobile-menu {
        padding: 60px 20px 20px;
    }

    .mobile-nav-list li {
        margin-bottom: 15px;
    }

    .mobile-nav-list a {
        font-size: 1.1rem;
    }
}

.show-menu .mobile-menu-overlay {
    display: block;
    opacity: 1;
}

.show-menu .mobile-menu {
    right: 0;
}

.close-menu {
    position: absolute;
    top: 25px;
    right: 25px;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--dark-text);
    cursor: pointer;
}

.mobile-nav-list li {
    margin-bottom: 20px;
}

.mobile-nav-list a {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--dark-text);
}

/* Hero Section */
.hero-section {
    height: 90vh;
    min-height: 600px;
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
        url('../imagenes/Fondo1.jpeg') no-repeat center center/cover;
    display: flex;
    align-items: center;
    position: relative;
    margin-top: 150px;
}

.hero-content {
    color: var(--white);
    max-width: 800px;
    text-align: center;
    margin: 0 auto;
    z-index: 2;
}

.hero-content h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 40px;
    font-weight: 400;
    opacity: 0.9;
}

@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2rem;
    }
    .hero-section {
        height: 70vh;
        min-height: 500px;
    }
}

/* Mejoras para tablets pequeñas */
@media (max-width: 600px) {
    .hero-content h1 {
        font-size: 1.8rem;
    }
    .hero-content p {
        font-size: 1rem;
    }
    .section-title {
        font-size: 1.8rem;
    }
}

/* Mejoras para móviles */
@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    #main-header {
        height: 80px;
    }

    .logo-link {
        height: 80px;
    }

    .logo-img {
        max-height: 60px;
    }

    .logo-full-text {
        font-size: 1.2rem;
    }

    .logo-text-group {
        margin-left: 5px;
    }

    .hero-section {
        margin-top: 80px;
        height: 60vh;
        min-height: 450px;
    }

    .hero-content h1 {
        font-size: 1.5rem;
        margin-bottom: 15px;
    }

    .hero-content p {
        font-size: 0.95rem;
        margin-bottom: 30px;
    }

    .btn {
        padding: 10px 25px;
        font-size: 0.9rem;
    }

    .section-title {
        font-size: 1.6rem;
        margin-bottom: 35px;
    }

    .identity-section,
    .services-section,
    .contact-section {
        padding: 50px 0;
    }

    .identity-card,
    .service-info {
        padding: 20px;
    }

    .service-image {
        height: 150px;
    }

    .contact-wrapper {
        gap: 30px;
    }

    .form-group input,
    .form-group textarea {
        padding: 12px;
        font-size: 0.95rem;
    }

    .info-card {
        padding: 15px;
        gap: 15px;
    }

    .contact-form-container h2 {
        font-size: 1.6rem;
    }
}

/* Mejoras para móviles muy pequeños */
@media (max-width: 360px) {
    .logo-full-text {
        font-size: 1rem;
    }

    .hero-content h1 {
        font-size: 1.3rem;
    }

    .hero-content p {
        font-size: 0.9rem;
    }

    .section-title {
        font-size: 1.4rem;
    }

    .service-info h3 {
        font-size: 1rem;
    }

    .service-info p {
        font-size: 0.85rem;
    }
}

/* Identity Section (Mission/Vision) */
.identity-section {
    padding: 80px 0;
    background: var(--white);
}

.identity-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
}

@media (min-width: 768px) {
    .identity-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.identity-card {
    background: var(--light-gray);
    padding: 40px;
    border-radius: 12px;
    text-align: center;
    transition: var(--transition);
    border: 1px solid transparent;
}

.identity-card:hover {
    background: var(--white);
    box-shadow: var(--box-shadow);
    border-color: #eee;
    transform: translateY(-5px);
}

.icon-box {
    width: 60px;
    height: 60px;
    background: rgba(46, 125, 50, 0.1);
    color: var(--primary-green);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin: 0 auto 20px;
}

.identity-card h3 {
    margin-bottom: 15px;
    color: var(--primary-dark);
}

/* Services Section */
.services-section {
    padding: 80px 0;
    background: var(--light-gray);
}

.section-title {
    text-align: center;
    font-size: 2.2rem;
    margin-bottom: 50px;
    color: var(--dark-text);
}

.services-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
}

@media (min-width: 600px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.service-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
    height: 100%;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
}

.service-image {
    height: 180px;
    background: #f5f5f5; /* Un gris más suave de fondo */
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 15px; /* Evita que la imagen toque los bordes */
}

.service-image img {
    width: 100%;
    height: 100%;
    object-fit: contain; /* Asegura que la imagen se vea completa */
    transition: transform 0.5s ease;
}

.service-card:hover .service-image img {
    transform: scale(1.1);
}

/* Placeholder styles removed as we now use real images */


.service-info {
    padding: 25px;
}

.service-info h3 {
    font-size: 1.1rem;
    margin-bottom: 10px;
    color: var(--primary-dark);
}

.service-info p {
    font-size: 0.9rem;
    color: var(--mid-gray);
    line-height: 1.5;
}

/* Clients Section */
.clients-section {
    padding: 80px 0;
    background: var(--white);
    overflow: hidden;
}

.clients-subtitle {
    text-align: center;
    color: var(--mid-gray);
    font-size: 1rem;
    margin-top: -30px;
    margin-bottom: 50px;
}

.carousel-container {
    position: relative;
    width: 100%;
    overflow: hidden;
    padding: 20px 0;
}

.carousel-track {
    display: flex;
    gap: 60px;
    animation: scroll 30s linear infinite;
    width: fit-content;
}

.carousel-track:hover {
    animation-play-state: paused;
}

.client-logo {
    flex-shrink: 0;
    width: 180px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--white);
    border-radius: 8px;
    padding: 15px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.client-logo:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.client-logo img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    filter: grayscale(100%);
    opacity: 0.7;
    transition: all 0.3s ease;
}

.client-logo:hover img {
    filter: grayscale(0%);
    opacity: 1;
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

/* Responsividad para el carrusel */
@media (max-width: 768px) {
    .clients-section {
        padding: 60px 0;
    }

    .carousel-track {
        gap: 40px;
        animation: scroll 25s linear infinite;
    }

    .client-logo {
        width: 150px;
        height: 80px;
        padding: 10px;
    }

    .clients-subtitle {
        font-size: 0.95rem;
        margin-bottom: 40px;
    }
}

@media (max-width: 480px) {
    .clients-section {
        padding: 50px 0;
    }

    .carousel-track {
        gap: 30px;
        animation: scroll 20s linear infinite;
    }

    .client-logo {
        width: 130px;
        height: 70px;
        padding: 8px;
    }

    .clients-subtitle {
        font-size: 0.9rem;
        padding: 0 20px;
    }
}

/* Contact Section */
.contact-section {
    padding: 80px 0;
    background: var(--primary-dark);
    /* Dark green background */
    color: var(--white);
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr;
    gap: 50px;
}

@media (min-width: 900px) {
    .contact-wrapper {
        grid-template-columns: 3fr 2fr;
        gap: 80px;
    }
}

.contact-form-container h2 {
    font-size: 2rem;
    margin-bottom: 10px;
}

.contact-form-container p {
    margin-bottom: 30px;
    opacity: 0.8;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 15px;
    border-radius: 6px;
    border: 1px solid #ddd;
    background: #f9f9f9;
    color: var(--dark-text);
    font-family: inherit;
    font-size: 1rem;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-lime);
    background: #f9f9f9;
}

.info-card {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
    border: 1px solid #ddd;
    color: var(--dark-text);
}

.info-icon {
    width: 45px;
    height: 45px;
    background: var(--accent-lime);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-dark);
    font-size: 1.2rem;
    flex-shrink: 0;
}

.info-block h4 {
    margin-bottom: 15px;
    color: var(--accent-lime);
    display: flex;
    align-items: center;
    gap: 10px;
}

.hours-list li {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
}

.status-badge {
    margin-top: 15px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--accent-lime);
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 1px;
}

.dot {
    width: 10px;
    height: 10px;
    background: var(--accent-lime);
    border-radius: 50%;
    display: block;
    box-shadow: 0 0 10px var(--accent-lime);
}

.mt-4 {
    margin-top: 2rem;
}

/* Footer */
.map-section iframe {
    display: block;
}

.main-footer {
    background: #0d260e;
    padding: 40px 0;
    color: #888;
    text-align: center;
    border-top: 4px solid var(--primary-green);
}

.footer-brand h4 {
    color: var(--white);
    margin-bottom: 5px;
}

.footer-brand p {
    font-size: 0.8rem;
    letter-spacing: 1px;
}

.social-links {
    margin: 20px 0;
}

.social-links a {
    color: #888;
    font-size: 1.5rem;
    margin: 0 10px;
    transition: color 0.3s;
}

.social-links a:hover {
    color: var(--white);
}

.copyright {
    font-size: 0.85rem;
}

/* Animations */
.animate-up {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s forwards;
}

.delay-1 {
    animation-delay: 0.2s;
}

.delay-2 {
    animation-delay: 0.4s;
}

.delay-3 {
    animation-delay: 0.6s;
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease-out;
}

.animate-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Mejoras de accesibilidad táctil para móviles */
@media (max-width: 768px) {
    .menu-toggle {
        padding: 10px;
        font-size: 1.8rem;
        min-width: 44px;
        min-height: 44px;
    }

    .close-menu {
        padding: 10px;
        min-width: 44px;
        min-height: 44px;
    }

    .mobile-nav-list a {
        display: block;
        padding: 12px 0;
        min-height: 44px;
    }

    .btn {
        min-height: 44px;
    }

    .social-links a {
        padding: 10px;
        min-width: 44px;
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }
}

/* Optimización de imágenes para móviles */
@media (max-width: 768px) {
    .logo-img,
    .service-image img {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}

/* Mejora del diseño de formularios en landscape móvil */
@media (max-width: 900px) and (max-height: 500px) {
    .hero-section {
        height: auto;
        min-height: 400px;
        padding: 100px 0 50px;
    }

    .contact-section {
        padding: 40px 0;
    }
}

/* Asegurar que el contenido no se desborde en pantallas pequeñas */
@media (max-width: 360px) {
    body {
        font-size: 14px;
    }

    .container {
        padding: 0 10px;
    }

    .container.header-content {
        padding: 0 10px;
    }
}