/* --- ESTILOS GENERALES Y RESET --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.6;
    background-color: #f9f9f9;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- CABECERA Y NAVEGACIÓN --- */
.main-header {
    background-color: #ffffff;
    padding: 1rem 0;
    border-bottom: 1px solid #ddd;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 70px;
    width: auto;
}

.main-nav ul {
    list-style: none;
    display: flex;
}

.main-nav ul li {
    margin-left: 30px;
}

.main-nav ul li a {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    font-size: 1rem;
    transition: color 0.3s ease;
    white-space: nowrap;
}

.main-nav ul li a:hover {
    color: #007BFF;
}

/* --- BOTÓN HAMBURGUESA Y MENÚ MÓVIL --- */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1001;
}

.menu-toggle .bar {
    display: block;
    width: 25px;
    height: 3px;
    background-color: #333;
    margin: 5px 0;
    transition: all 0.3s ease-in-out;
}


/* --- SECCIÓN HERO CON IMAGEN DE FONDO --- */
.hero-section {
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('images/fondo.svg');
    background-size: cover;
    background-position: center;
    text-align: center;
    padding: 120px 0;
}

.hero-section h1 {
    font-size: 2.8rem;
    margin-bottom: 15px;
    color: #ffffff;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.hero-section p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 30px auto;
    color: #ffffff;
}

.cta-button {
    display: inline-block;
    background-color: #007BFF;
    color: #fff;
    padding: 15px 30px;
    border-radius: 5px;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.cta-button:hover {
    background-color: #0056b3;
}

/* --- SECCIÓN SERVICIOS --- */
.services-section {
    padding: 80px 0;
    background-color: #f0f4f8;
}

.services-section h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 10px;
    color: #2c3e50;
}

.section-subtitle {
    text-align: center;
    font-size: 1.1rem;
    color: #555;
    max-width: 600px;
    margin: 0 auto 50px auto;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.service-card {
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.15);
}

.service-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.card-content {
    padding: 25px;
    text-align: center;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card-content h3 {
    font-size: 1.4rem;
    color: #007BFF;
    margin-bottom: 15px;
}

.card-content p {
    font-size: 1rem;
    color: #444;
    flex-grow: 1;
}


/* --- SECCIÓN SOBRE NOSOTROS --- */
.about-section {
    background-color: #ffffff;
    padding: 80px 0;
}

.about-container {
    display: flex;
    align-items: center;
    gap: 50px;
}

.about-image {
    flex: 1;
}

.about-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.about-content {
    flex: 1;
}

.about-content h2 {
    font-size: 2.5rem;
    color: #2c3e50;
    margin-bottom: 20px;
}
.about-content h3 {
    font-size: 1.5rem;
    color: #007BFF;
    margin-bottom: 20px;
    font-weight: 600;
}

.about-content p {
    margin-bottom: 15px;
    font-size: 1.1rem;
}


/* --- SECCIÓN CONTACTO --- */
.contact-section {
    padding: 80px 0;
    background-color: #f0f4f8;
}

.contact-container {
    max-width: 800px; /* Limitamos el ancho para que no sea excesivo */
    margin: 0 auto;
    background-color: #fff;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.07);
}

.contact-info-form {
    display: grid;
    grid-template-columns: 1fr 1.5fr; /* Info a la izq, form a la derecha */
    gap: 40px;
    margin-bottom: 40px; /* Espacio entre el formulario y el mapa */
}

.contact-map iframe {
    width: 100%;
    height: 400px; /* Altura fija para el mapa */
    border-radius: 8px;
    border: 1px solid #ddd; /* Un borde sutil */
}

.contact-details h3, .contact-form h3 {
    font-size: 1.8rem;
    color: #2c3e50;
    margin-bottom: 20px;
}

.contact-details p {
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.contact-form input, .contact-form textarea {
    width: 100%;
    padding: 12px;
    margin-bottom: 15px;
    border-radius: 5px;
    border: 1px solid #ccc;
    font-family: inherit;
    font-size: 1rem;
}

.contact-form button {
    width: 100%;
    border: none;
}


/* --- FOOTER Y PÁGINAS LEGALES --- */
.main-footer {
    background-color: #2c3e50;
    color: #fff;
    text-align: center;
    padding: 20px 0;
}

.main-footer .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.footer-nav a {
    color: #ffffff;
    text-decoration: none;
    margin: 0 10px;
    transition: text-decoration 0.3s ease;
}

.footer-nav a:hover {
    text-decoration: underline;
}

.legal-page {
    padding: 60px 0;
    background-color: #ffffff;
}

.legal-page h1 {
    font-size: 2.5rem;
    margin-bottom: 30px;
    color: #2c3e50;
}

.legal-page p, .legal-page li {
    margin-bottom: 15px;
    line-height: 1.7;
}

/* --- ADAPTACIÓN A MÓVILES (Media Queries) --- */
@media (max-width: 850px) {
    .menu-toggle {
        display: block;
    }

    .main-nav {
        display: none;
        position: absolute;
        top: 90px;
        left: 0;
        width: 100%;
        background-color: #ffffff;
        box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    }
    
    .main-nav.is-active {
        display: block;
    }

    .main-nav ul {
        flex-direction: column;
        align-items: center;
        padding: 20px 0;
    }

    .main-nav ul li {
        margin: 15px 0;
    }

    .menu-toggle.is-active .bar:nth-child(2) {
        opacity: 0;
    }
    .menu-toggle.is-active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }
    .menu-toggle.is-active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .about-container, .contact-info-form { /* Ajustamos aquí */
        flex-direction: column;
        grid-template-columns: 1fr;
    }
    .hero-section h1 { font-size: 2.2rem; }
    .hero-section { padding: 80px 0; }
}