/**
 * Estilos para o carrossel de categorias com efeito Glassmorphism
 */

/* Seção geral */
.section-categorias {
  max-width: 1200px;
  margin: 30px auto;
  padding: 20px;
}

.section-categorias h2 {
  text-align: center;
  font-weight: 700;
  font-size: 1.8rem;
  color: #5f259f; /* Roxo principal */
  margin-bottom: 1.5rem;
}

/* Carrossel e wrapper */
.carousel-wrapper {
  display: flex;
  align-items: center;
  position: relative;
  padding: 10px 0;
  width: 100%;
  overflow: hidden;
}

.carousel {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  scroll-behavior: smooth;
  padding: 10px 0;
  -ms-overflow-style: none; /* IE e Edge */
  scrollbar-width: none; /* Firefox */
}

.carousel::-webkit-scrollbar {
  display: none; /* Chrome, Safari e Opera */
}

/* Cards de categoria com efeito Glassmorphism */
.category-card {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px); /* Safari */
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.5);
  min-width: 220px;
  max-width: 250px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: block;
}

.category-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  border: 1px solid rgba(160, 80, 227, 0.3);
}

.category-card img {
  width: 100%;
  height: 140px;
  object-fit: cover;
  border-radius: 12px 12px 0 0;
  transition: transform 0.5s ease;
}

.category-card:hover img {
  transform: scale(1.05);
}

.category-content {
  padding: 15px;
  text-align: center;
}

.category-title {
  font-size: 1.1rem;
  font-weight: bold;
  margin-bottom: 5px;
  color: #773bbe; /* Destaque roxo */
}

.category-desc {
  font-size: 0.9rem;
  color: #555;
  line-height: 1.4;
}

/* Setas de navegação estilo Feather */
.arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(119, 59, 190, 0.8); /* Roxo semi-transparente */
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  color: #fff;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  border: none;
  z-index: 10;
}

.arrow:hover {
  background: rgba(160, 80, 227, 0.9); /* Roxo mais claro ao passar o cursor */
  transform: translateY(-50%) scale(1.1);
}

.arrow:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(160, 80, 227, 0.3);
}

.arrow-left {
  left: 10px;
}

.arrow-right {
  right: 10px;
}

.arrow svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

/* Fallback para navegadores que não suportam backdrop-filter */
@supports not ((backdrop-filter: blur(10px)) or (-webkit-backdrop-filter: blur(10px))) {
  .category-card {
    background: rgba(255, 255, 255, 0.95);
  }
  
  .arrow {
    background: rgba(119, 59, 190, 0.95);
  }
}

/* Responsividade */
@media (max-width: 768px) {
  .carousel-wrapper {
    padding: 0 8px;
  }

  .category-card {
    min-width: 180px;
  }
  
  .category-card img {
    height: 120px;
  }
  
  .category-content {
    padding: 10px;
  }
  
  .category-title {
    font-size: 1rem;
  }
  
  .category-desc {
    font-size: 0.8rem;
  }
  
  .arrow {
    width: 36px;
    height: 36px;
  }
  
  .arrow svg {
    width: 18px;
    height: 18px;
  }
}

@media (max-width: 576px) {
  .category-card {
    min-width: 160px;
  }
  
  .category-card img {
    height: 100px;
  }
  
  .arrow {
    width: 32px;
    height: 32px;
  }
  
  .arrow svg {
    width: 16px;
    height: 16px;
  }
}
