/* -------------------------------------- */
/* 0. Configuración Global / Reset */
/* -------------------------------------- */
:root {
    --color-primary: #007BFF;
    --color-secondary: #28a745;
    --color-dark: #343a40;
    --color-light: #f8f9fa;
    --color-text: #495057;
    --padding-section: 60px 20px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: sans-serif;
    line-height: 1.6;
    color: var(--color-text);
    background-color: white;
}

a {
    text-decoration: none;
    color: var(--color-primary);
}

/* -------------------------------------- */
/* 1. ENCABEZADO (HEADER) y Navegación */
/* -------------------------------------- */
.header {
    background-color: var(--color-dark);
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky; /* Fijo en la parte superior */
    top: 0;
    z-index: 1000;
}

.logo {
    font-size: 1.5em;
    font-weight: bold;
}

/* Menú de Hamburguesa (Solo Visible en Móvil) */
.menu-toggle {
    background: none;
    border: none;
    cursor: pointer;
    display: flex; /* Mostrar en móvil */
    flex-direction: column;
    justify-content: space-around;
    height: 24px;
    width: 30px;
    padding: 0;
    z-index: 10; /* Asegura que esté sobre el nav-list */
}

.menu-toggle .bar {
    display: block;
    width: 100%;
    height: 3px;
    background-color: white;
    border-radius: 10px;
    transition: all 0.3s ease-in-out;
}

/* Lista de Navegación */
.nav-list {
    list-style: none;
    position: fixed;
    top: 60px; /* Debajo del header */
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: var(--color-dark);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 50px;
    transform: translateX(100%); /* Oculto por defecto */
    transition: transform 0.3s ease-in-out;
}

.nav-list.active {
    transform: translateX(0); /* Mostrar cuando esté activo */
}

.nav-list li {
    margin: 15px 0;
}

.nav-list a {
    color: white;
    font-size: 1.2em;
    padding: 10px 0;
    display: block;
    transition: color 0.2s;
}

.nav-list a:hover {
    color: var(--color-primary);
}

/* -------------------------------------- */
/* 2. ESTILOS GENERALES DE SECCIÓN */
/* -------------------------------------- */
.section {
    padding: var(--padding-section);
    text-align: center;
}

.section h2 {
    font-size: 2em;
    margin-bottom: 25px;
    color: var(--color-dark);
}

/* Botones */
.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 5px;
    font-weight: bold;
    margin-top: 20px;
    transition: background-color 0.3s;
}

.primary-btn {
    background-color: var(--color-primary);
    color: white;
}

.primary-btn:hover {
    background-color: #0056b3;
}

.secondary-btn {
    background-color: var(--color-secondary);
    color: white;
}

.secondary-btn:hover {
    background-color: #1e7e34;
}

/* -------------------------------------- */
/* 3. SECCIÓN PRESENTACIÓN (HERO) */
/* -------------------------------------- */
.hero {
    background-color: var(--color-light);
    min-height: 80vh; /* Ocupa gran parte de la pantalla */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.hero h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
    color: var(--color-primary);
}

/* -------------------------------------- */
/* 4. SECCIONES SERVICIOS Y PRODUCTOS */
/* -------------------------------------- */
.service-container, .product-container {
    display: flex;
    flex-direction: column; /* Apilados en móvil */
    gap: 20px;
    margin-top: 30px;
}

.service-card, .product-card {
    background-color: white;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.service-card h3, .product-card h4 {
    color: var(--color-primary);
    margin-bottom: 10px;
}

/* Estilo para distinguir las secciones */
.services {
    background-color: #f1f1f1;
}

/* -------------------------------------- */
/* 5. CONTACTO (Extra) */
/* -------------------------------------- */
.contact {
    background-color: var(--color-dark);
    color: white;
}

.contact h2 {
    color: white;
}


/* -------------------------------------- */
/* 6. MEDIA QUERY (Diseño para Escritorio/Tablet) */
/* -------------------------------------- */
@media (min-width: 768px) {
    
    /* Encabezado: Ocultar hamburguesa, mostrar lista */
    .menu-toggle {
        display: none; /* Ocultar en escritorio */
    }

    .nav-list {
        position: static; /* Volver a flujo normal */
        transform: translateX(0); /* Siempre visible */
        flex-direction: row;
        width: auto;
        height: auto;
        padding-top: 0;
        background-color: transparent;
    }

    .nav-list li {
        margin: 0 15px;
    }

    .nav-list a {
        color: white; /* Color normal */
        padding: 5px 0;
        font-size: 1em;
    }
    
    /* Secciones: Mostrar tarjetas en fila */
    .service-container {
        flex-direction: row;
        justify-content: center;
    }

    .service-card {
        flex: 1;
        max-width: 300px;
    }

    .product-container {
        flex-direction: row;
        justify-content: center;
    }

    .product-card {
        flex: 1;
        max-width: 400px;
    }
}

