/* Estilos generales */
.hidden {
  display: none;
}

/* Estilos de búsqueda y filtros */
.search-container {
  position: relative;
  margin-bottom: 2rem;
}

.search-input {
  width: 100%;
  padding: 1rem;
  border: 2px solid #e5e7eb;
  border-radius: 0.5rem;
  font-size: 1rem;
  transition: border-color 0.2s;
}

.search-input:focus {
  border-color: #3b82f6;
  outline: none;
}

.autocomplete-list {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  z-index: 10;
}

.autocomplete-item {
  padding: 0.75rem 1rem;
  cursor: pointer;
}

.autocomplete-item:hover {
  background: #f3f4f6;
}

.filter-container {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.filter-button {
  padding: 0.5rem 1rem;
  border: 2px solid #3b82f6;
  border-radius: 0.5rem;
  background: #f3f4f6;
  color: #3b82f6;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.filter-button:hover {
  background: #e5e7eb;
}

.filter-button.active {
  background: #3b82f6;
  border-color: #3b82f6;
  color: white;
  box-shadow: 0 2px 4px rgba(59, 130, 246, 0.25);
}

/* Estilos del lightbox */
.lightbox-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.lightbox-content {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
}

.lightbox-image {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
}

.lightbox-caption {
  color: white;
  text-align: center;
  padding: 1rem;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
  position: absolute;
  background: rgba(0, 0, 0, 0.5);
  color: white;
  border: none;
  cursor: pointer;
  padding: 1rem;
  transition: background 0.2s;
}

.lightbox-close {
  top: 1rem;
  right: 1rem;
  font-size: 2rem;
}

.lightbox-prev,
.lightbox-next {
  top: 50%;
  transform: translateY(-50%);
  font-size: 2rem;
}

.lightbox-prev {
  left: 1rem;
}

.lightbox-next {
  right: 1rem;
}

/* Estilos de los botones de compartir */
.share-container {
  display: flex;
  gap: 0.5rem;
  margin-top: 1rem;
}

.share-button {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s;
}

.share-button:hover {
  transform: scale(1.1);
}

.share-twitter {
  background: #1DA1F2;
  color: white;
}

.share-facebook {
  background: #4267B2;
  color: white;
}

.share-linkedin {
  background: #0077B5;
  color: white;
}

.share-whatsapp {
  background: #25D366;
  color: white;
}

/* Estilos de las tarjetas de proyectos */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
}

.project-card {
  border-radius: 0.5rem;
  overflow: hidden;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s;
}

.project-card:hover {
  transform: translateY(-4px);
}

.project-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.project-card h3 {
  padding: 1rem;
  margin: 0;
  font-size: 1.25rem;
  font-weight: 600;
}

.project-card p {
  padding: 0 1rem 1rem;
  margin: 0;
  color: #6b7280;
}

.project-card .tags {
  padding: 0 1rem 1rem;
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.tag {
  padding: 0.25rem 0.75rem;
  background: #f3f4f6;
  border-radius: 9999px;
  font-size: 0.875rem;
  color: #4b5563;
}

/* Estilos responsivos */
@media (max-width: 640px) {
  .projects-grid {
    grid-template-columns: 1fr;
  }
  
  .filter-container {
    flex-direction: column;
  }
  
  .filter-button {
    width: 100%;
  }
  
  .lightbox-prev,
  .lightbox-next {
    padding: 0.5rem;
    font-size: 1.5rem;
  }
}
