/* Variables CSS */
:root {
    --primary-color: #1355a1;
    --secondary-color: #0d3d6b;
    --accent-color: #cce6ff;
    --text-color: #333;
    --background-color: #f4f4f9;
    --max-width: 1200px; /* Ancho máximo del contenido */
}

/* Estilos generales */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
}

/* Header */
header {
    width: 95%;
    background-color: var(--primary-color);
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.logo-container {
    display: flex;
    align-items: center;
}

.logo {
    height: 50px;
    margin-right: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 5px;
}

.titles {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.main-title {
    margin: 0;
    font-size: 1.6rem;
    color: white;
}

.subtitle {
    margin: 0;
    font-size: 1.2rem;
    color: var(--accent-color);
    font-weight: normal;
}

nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}

nav ul li {
    margin-left: 20px;
}

nav ul li a {
    color: white;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

nav ul li a:hover {
    color: var(--accent-color);
}

/* Contenido principal */
main {
    padding: 10px;
    max-width: var(--max-width);
    margin: 0 auto; /* Centrar el contenido */
}

section {
    margin-bottom: 20px;
    padding: 20px 10px;
}

h1, h2 {
    color: var(--primary-color);
}

/* Tarjetas de servicios */
.card-container {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.card {
    background-color: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    width: calc(33.333% - 40px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
    text-align: center;
    overflow: hidden;
    flex-grow: 1; /* Mejora la distribución en pantallas pequeñas */
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    background-color: var(--accent-color);
}

/* Estilo para las imágenes dentro de las tarjetas */
.card img.map-image {
    border: 1px solid black; /* Borde negro de 2px */
    border-radius: 8px; /* Bordes redondeados (opcional) */
}

.card h3 {
    margin-top: 0;
    color: var(--primary-color);
}

.card p {
    color: #666;
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    background-color: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.btn:hover {
    background-color: var(--secondary-color);
    transform: scale(1.05);
}

/* contacto */
.contact {
    margin: 0;
    line-height: 1;
    font-weight: normal;
    text-align: center;
}

/* Footer */
footer {
    background-color: var(--primary-color);
    color: white;
    padding: 20px;
    text-align: center;
}

footer .footer-content {
    max-width: var(--max-width);
    margin: 0 auto;
}

footer ul {
    list-style: none;
    padding: 0;
    display: flex;
    justify-content: center;
    margin-top: 10px;
}

footer ul li {
    margin: 0 15px;
}

footer ul li a {
    color: white;
    text-decoration: none;
    transition: color 0.3s ease;
}

footer ul li a:hover {
    color: var(--accent-color);
}

/* Responsive Design */
@media (max-width: 768px) {
    .card {
        width: calc(50% - 20px);
    }

    /* Menú desplegable para móviles */
    nav ul {
        flex-direction: column;
        align-items: center;
    }

    nav ul li {
        margin: 10px 0;
    }
}

@media (max-width: 480px) {
    .card {
        width: 100%;
    }

    footer ul {
        flex-direction: column;
        align-items: center;
    }

    footer ul li {
        margin: 5px 0;
    }
}