/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --color-primary: #2C7A7B;
    --color-secondary: #4FD1C7;
    --color-accent: #38B2AC;
    --color-dark: #1A202C;
    --color-gray: #718096;
    --color-light-gray: #F7FAFC;
    --color-white: #FFFFFF;
    --color-text: #2D3748;
    --font-primary: 'Montserrat', sans-serif;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.15);
    --border-radius: 8px;
    --transition: all 0.3s ease;
}

body {
    font-family: var(--font-primary);
    line-height: 1.6;
    color: var(--color-text);
    font-size: 16px;
}

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

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 {
    font-size: 2.5rem;
    font-weight: 700;
}

h2 {
    font-size: 2rem;
    color: var(--color-primary);
}

h3 {
    font-size: 1.5rem;
}

p {
    margin-bottom: 1rem;
    color: var(--color-gray);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 12px 24px;
    border: none;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    justify-content: center;
}

.btn-primary {
    background-color: var(--color-primary);
    color: var(--color-white);
}

.btn-primary:hover {
    background-color: #245E5F;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background-color: var(--color-secondary);
    color: var(--color-dark);
}

.btn-secondary:hover {
    background-color: #38B2AC;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-contact {
    background-color: var(--color-accent);
    color: var(--color-white);
    padding: 16px 32px;
    font-size: 1.1rem;
    border-radius: 30px;
    min-width: 200px;
}

.btn-contact:hover {
    background-color: var(--color-primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Header */
.header {
    background-color: var(--color-white);
    box-shadow: var(--shadow);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

.nav-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo-img {
    height: 50px;
    width: auto;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-list a {
    text-decoration: none;
    color: var(--color-text);
    font-weight: 500;
    transition: var(--transition);
}

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

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

/* Hero Section */
.hero {
    background-image: url('../images/mfivyuzwk9kr7ztwyfd7.webp');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    /* background: linear-gradient(135deg, var(--color-light-gray) 0%, #E2E8F0 100%); */
    padding: 150px;
    text-align: center;
    position: relative;
}

.hero::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.4); /* Dark overlay for better text readability */
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
}

.hero-image {
    margin-bottom: 2rem;
}

.hero-image img {
    max-width: 100%;
    height: auto;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
}

.hero-text h1 {
    color: var(--color-primary);
    margin-bottom: 1rem;
}

.hero-text p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: var(--color-gray);
}

/* About Section */
.about {
    padding: 80px 0;
    background-color: var(--color-light-gray);
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.feature-card {
    background-color: var(--color-white);
    padding: 2rem;
    border-radius: var(--border-radius);
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.feature-card img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    margin-bottom: 1rem;
}

.feature-card h3 {
    color: var(--color-primary);
    margin-bottom: 1rem;
}

/* Company Info Section */
.company-info {
    padding: 80px 0;
}

.company-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.company-text h2 {
    margin-bottom: 1.5rem;
}

.company-text p {
    font-size: 1.1rem;
    line-height: 1.7;
}

.company-image img {
    max-width: 100%;
    height: auto;
    width: 350px;
    border-radius: var(--border-radius);
    /* box-shadow: var(--shadow); */
}

.company-image {
    display: flex;
    justify-content: center; /* Center image on mobile */
}

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

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.service-card {
    background-color: var(--color-white);
    padding: 2.5rem;
    border-radius: var(--border-radius);
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.service-icon {
    font-size: 3rem;
    color: var(--color-primary);
    margin-bottom: 1.5rem;
}

.service-card h3 {
    color: var(--color-primary);
    margin-bottom: 1rem;
    min-height: 60px; /* Altura mínima para los títulos */
    display: flex;
    align-items: center;
    justify-content: center;
}

.service-card p {
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.services-cta {
    text-align: center;
}

.service-card-mecanica {
    position: relative;
    overflow: hidden;
    padding: 0;
    z-index: 1;
}

.service-card-mecanica::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../images/dqbyxkggpb0bsvspitq6.webp');
    background-size: cover;
    background-position: center;
    opacity: 0.2;
    z-index: -1;
}

.service-card-soldaduras {
    position: relative;
    overflow: hidden;
    padding: 0;
    z-index: 1;
}

.service-card-soldaduras::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../images/opebruwfk4q9n7vpnevd.webp');
    background-size: cover;
    background-position: center;
    opacity: 0.2;
    z-index: -1;
}

.service-card-mantenimiento {
    position: relative;
    overflow: hidden;
    padding: 0;
    z-index: 1;
}

.service-card-mantenimiento::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../images/rxm4w182ggw4uz0cd8ve.webp');
    background-size: cover;
    background-position: center;
    opacity: 0.2;
    z-index: -1;
}

.service-card-content {
    position: relative;
    padding: 2.5rem;
    z-index: 2;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;;
    /* background: linear-gradient(135deg,rgba(255, 255, 255, 0.95) 0%,rgba(255, 255, 255, 0.85) 100%); */
}

.service-description {
    flex-grow: 1;
    margin-bottom: 1.5rem;
    line-height: 1.6;
    min-height: 80px; /* Altura mínima para los párrafos */
}

.service-button-container {
    margin-top: auto;
    display: flex;
    justify-content: center;
}

.service-icon {
    font-size: 3rem;
    color: var(--color-primary);
    margin-bottom: 1.5rem;
    height: 60px; /* Altura fija para los íconos */
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Contact Form Section */
.contact-form-section {
    padding: 80px 0;
    position: relative;
    /* background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent) 100%); */
    /* background: linear-gradient(rgba(44, 122, 123, 0.85), rgba(56, 178, 172, 0.85)), url('../images/wprrqeosd9ucrdthubiz.webp'); */
    background: url('../images/wprrqeosd9ucrdthubiz.webp');;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    /* background-attachment: fixed; */
}

.contact-form-wrapper {
    max-width: 600px;
    margin: 0 auto;
}

.contact-form {
    background-color: rgba(255, 255, 255, 0.7);
    padding: 3rem;
    border-radius: var(--border-radius);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.contact-form h3 {
    text-align: center;
    color: var(--color-primary);
    margin-bottom: 2rem;
    font-size: 1.8rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--color-primary);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #E2E8F0;
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: var(--transition);
    font-family: var(--font-primary);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(44, 122, 123, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

/* Contact Section */
.contact {
    padding: 80px 0;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.contact-item {
    text-align: center;
}

.contact-buttons {
    display: flex;
    justify-content: center;
    gap: 50px; /* Espacio reducido entre botones */
    margin-bottom: 2rem;
}

.contact-email {
    text-align: center;
    margin-bottom: 2rem;
}

.contact-email a {
    color: var(--color-primary);
    text-decoration: none;
    font-size: 1.2rem;
    font-weight: 600;
}

.contact-email a:hover {
    text-decoration: underline;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1rem;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background-color: var(--color-primary);
    color: var(--color-white);
    border-radius: 50%;
    text-decoration: none;
    font-size: 1.2rem;
    transition: var(--transition);
}

.social-link:hover {
    background-color: var(--color-accent);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

/* Footer */
.footer {
    background-color: var(--color-primary);
    color: var(--color-white);
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
    align-items: center;
}

.footer-info {
    text-align: left;
}

.footer-info h3 {
    color: var(--color-white);
    margin-bottom: 1rem;
}

.footer-info p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0.5rem;
}

.footer-main-logo {
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
}

.footer-main-logo img {
    max-width: 80%;
    height: auto;
    max-height: 120px;
    filter: brightness(0) invert(1);
}

.footer-secondary-logo {
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
}

.footer-secondary-logo img {
    max-width: 100%;
    height: auto;
    max-height: 150px;
}

.footer-logo {
    text-align: center;
}

.footer-logo img {
    max-width: 150px;
    height: auto;
    filter: brightness(0) invert(1);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.7);
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-list {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: block;
    }
    
    .hero {
        padding: 100px 0 60px;
    }
    
    .hero-text h1 {
        font-size: 2rem;
    }
    
    .hero-text p {
        font-size: 1rem;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .company-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .contact-form {
        padding: 2rem;
    }
    
    .contact-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .btn-contact {
        /* min-width: auto; */
        width: 100%;
        max-width: 250px;
    }

    .contact-buttons {
        flex-direction: column;
        align-items: center;
        gap: 8px; /* Aún menos espacio en móvil */
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .hero-text h1 {
        font-size: 1.8rem;
    }
    
    .feature-card,
    .service-card {
        padding: 1.5rem;
    }
    
    .contact-form {
        padding: 1.5rem;
    }
    
    .section-header h2 {
        font-size: 1.5rem;
    }
}

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

/* Loading animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.feature-card,
.service-card {
    animation: fadeInUp 0.6s ease-out;
}

/* Focus styles for accessibility */
.btn:focus,
input:focus,
textarea:focus {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .header,
    .contact-form-section {
        display: none;
    }
}
