/* ==========================================
   1. VARIABLES Y REINICIO INICIAL
   ========================================== */
:root {
  --primary-color: #e15729;
  --primary-hover: #c4451c;
  --bg-color: #f8f9fa;
  --card-bg: #ffffff;
  --text-main: #2b2d42;
  --text-muted: #6c757d;
  --border-color: #e9ecef;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.1);
  --radius: 8px;
  --transition: all 0.25s ease;
}

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

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background-color: var(--bg-color);
  color: var(--text-main);
  line-height: 1.6;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

ul {
  list-style: none;
}

/* ==========================================
   2. CABECERA (HEADER)
   ========================================== */
header {
  background-color: #ffffff;
  padding: 1rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  z-index: 100;
}

.logo h1 {
  font-size: 1.8rem;
  color: var(--primary-color);
  font-weight: 800;
  letter-spacing: -0.5px;
}

.search-bar {
  display: flex;
  width: 100%;
}

.search-bar input {
  flex: 1;
  padding: 0.6rem 1rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius) 0 0 var(--radius);
  outline: none;
  font-size: 0.95rem;
  transition: var(--transition);
}

.search-bar input:focus {
  border-color: var(--primary-color);
}

.search-bar button {
  background-color: var(--primary-color);
  color: white;
  border: none;
  padding: 0.6rem 1.2rem;
  border-radius: 0 var(--radius) var(--radius) 0;
  cursor: pointer;
  font-weight: 600;
  transition: var(--transition);
}

.search-bar button:hover {
  background-color: var(--primary-hover);
}

.user-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.95rem;
  font-weight: 500;
}

.user-actions a:hover {
  color: var(--primary-color);
}

#cart-count {
  background-color: var(--primary-color);
  color: white;
  padding: 2px 7px;
  border-radius: 50%;
  font-size: 0.8rem;
  font-weight: bold;
}

/* ==========================================
   3. NAVEGACI脫N (NAV)
   ========================================== */
nav {
  background-color: #ffffff;
  border-bottom: 1px solid var(--border-color);
  padding: 0.5rem 1.5rem;
  overflow-x: auto; /* Permite scroll horizontal en m贸viles si no cabe */
}

nav ul {
  display: flex;
  gap: 1.5rem;
  white-space: nowrap;
}

nav a {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-main);
  padding: 0.4rem 0;
  display: inline-block;
}

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

/* ==========================================
   4. CONTENIDO PRINCIPAL (MAIN)
   ========================================== */
main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1.5rem;
}

/* Hero / Banner */
.hero {
  background: linear-gradient(135deg, var(--primary-color), #ff8c61);
  color: white;
  padding: 3rem 1.5rem;
  border-radius: var(--radius);
  text-align: center;
  margin-bottom: 2.5rem;
  box-shadow: var(--shadow-md);
}

.hero h2 {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.hero p {
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
  opacity: 0.9;
}

.hero .btn {
  display: inline-block;
  background-color: white;
  color: var(--primary-color);
  padding: 0.75rem 1.8rem;
  border-radius: var(--radius);
  font-weight: bold;
  box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

.hero .btn:hover {
  transform: translateY(-2px);
  background-color: #f8f9fa;
}

/* Secci贸n de Productos */
.featured-products h2 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  position: relative;
}

.featured-products h2::after {
  content: '';
  display: block;
  width: 50px;
  height: 3px;
  background-color: var(--primary-color);
  margin-top: 4px;
  border-radius: 2px;
}

.products-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

.product-card {
  background-color: var(--card-bg);
  border-radius: var(--radius);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
  transition: var(--transition);
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.product-card img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: calc(var(--radius) - 2px);
  margin-bottom: 1rem;
}

.product-card h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.product-card .price {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 1rem;
}

.product-card .old-price {
  font-size: 0.9rem;
  color: var(--text-muted);
  text-decoration: line-through;
  margin-left: 0.5rem;
  font-weight: normal;
}

.btn-add-cart {
  margin-top: auto;
  background-color: var(--text-main);
  color: white;
  border: none;
  padding: 0.75rem;
  border-radius: var(--radius);
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.btn-add-cart:hover {
  background-color: var(--primary-color);
}

/* ==========================================
   5. PIE DE P脕GINA (FOOTER)
   ========================================== */
footer {
  background-color: #1a1d20;
  color: #adb5bd;
  padding: 2.5rem 1.5rem 1.5rem;
  margin-top: 3rem;
}

.footer-sections {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.footer-col h4 {
  color: white;
  margin-bottom: 1rem;
  font-size: 1.1rem;
}

.footer-col ul li {
  margin-bottom: 0.5rem;
}

.footer-col a:hover {
  color: var(--primary-color);
}

footer hr {
  border: 0;
  border-top: 1px solid #343a40;
  margin: 2rem 0 1rem;
}

.copyright {
  text-align: center;
  font-size: 0.85rem;
}

.logo {
  display: flex;
  flex-direction: column;
}

.user-greeting {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: -2px;
}

/* ==========================================
   6. RESPONSIVO: PANTALLAS MEDIANAS Y ESCRITORIO
   ========================================== */

/* Tablet (>= 600px) */
@media (min-width: 600px) {
  .products-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-sections {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Escritorio (>= 900px) */
@media (min-width: 900px) {
  header {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 3rem;
  }

  .search-bar {
    width: 40%;
  }

  .user-actions {
    gap: 1.5rem;
  }

  nav {
    padding: 0.75rem 3rem;
  }

  nav ul {
    justify-content: flex-start;
    gap: 2.5rem;
  }

  main {
    padding: 2.5rem 3rem;
  }

  .hero {
    padding: 4rem 2rem;
  }

  .hero h2 {
    font-size: 2.5rem;
  }

  .products-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}




.btn-ingenieria {
  display: inline-flex;
  align-items: center;
  gap: 8px; /* Espacio entre el texto y la imagen */
  padding: 10px 20px;
  background-color: #0056b3; /* Color de fondo del botón */
  color: #ffffff; /* Color del texto */
  text-decoration: none; /* Quita el subrayado de enlace */
  font-family: sans-serif;
  font-weight: bold;
  border-radius: 6px; /* Bordes redondeados */
  transition: background-color 0.2s ease;
}

/* Efecto al pasar el cursor */
.btn-ingenieria:hover {
  background-color: #003d80;
}

/* Tamaño de la imagen dentro del botón */
.logo-btn img {
  height: 24px; /* Ajusta la altura de tu logo según necesites */
  width: auto;
  vertical-align: middle;
}







