/* Estilos para a página de índice */
.index-page {
  font-family: 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

.index-page .page-inner {
  padding: 30px;
  height: 100%;
  display: flex;
  flex-direction: column;
}

/* Cabeçalho */
.index-page .page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  border-bottom: 2px solid #2c3e50;
  padding-bottom: 15px;
}

.index-page .index-title {
  font-size: 28px;
  font-weight: 700;
  color: #2c3e50;
}

.index-page .page-number {
  font-size: 16px;
  color: #7f8c8d;
  font-weight: 500;
}

/* Conteúdo principal */
.index-page .index-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Campo de busca */
.index-page .search-container {
  margin-bottom: 10px;
}

.index-page .search-wrapper {
  position: relative;
  max-width: 600px;
  margin: 0 auto;
  width: 100%;
}

.index-page .search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #7f8c8d;
  pointer-events: none;
}

.index-page #indexSearch {
  width: 100%;
  padding: 12px 40px;
  border: 2px solid #ddd;
  border-radius: 30px;
  font-size: 16px;
  transition: all 0.3s;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.index-page #indexSearch:focus {
  outline: none;
  border-color: #3498db;
  box-shadow: 0 2px 15px rgba(52, 152, 219, 0.15);
}

.index-page #indexSearchProducts {
  width: 100%;
  padding: 12px 40px;
  border: 2px solid #ddd;
  border-radius: 30px;
  font-size: 16px;
  transition: all 0.3s;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.index-page #indexSearchProducts:focus {
  outline: none;
  border-color: #3498db;
  box-shadow: 0 2px 15px rgba(52, 152, 219, 0.15);
}

.index-page .clear-search {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #7f8c8d;
  cursor: pointer;
  padding: 5px;
  display: none;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.index-page .clear-search:hover {
  opacity: 1;
}

/* Navegação alfabética */
.index-page .alphabet-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  column-gap: 15px;
  max-width: 800px;
  padding: 10px 0;
}

.index-page .letter-btn {
  aspect-ratio: 1 / 1; /* mantém quadrado */
  width: clamp(50px, 8vh, 100px);
  height: clamp(50px, 8vh, 100px);
  font-size: clamp(14px, 2vw, 20px);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #ccc;
  font-size: 20px;
  display: flex;
  background-color: #fff;
  border: 1px solid #ddd;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
  color: #34495e;
  transition: all 0.2s;
}

.index-page .letter-btn:hover {
  background-color: #f1f9ff;
  border-color: #3498db;
  transform: translateY(-2px);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
}

.index-page .letter-btn.active {
  background-color: #3498db;
  color: white;
  border-color: #3498db;
}

/* Área de resultados */
.index-page .index-results {
  flex: 1;
  overflow-y: auto;
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
  padding: 20px;
  margin-top: 10px;
}

.index-page .index-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 200px;
  color: #95a5a6;
  font-size: 18px;
  text-align: center;
}

.index-page .no-results,
.index-page .search-error {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 200px;
  color: #e74c3c;
  font-size: 18px;
  text-align: center;
}

/* Resultados da busca */
.index-page .results-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.index-page .result-section-title {
  font-size: 18px;
  font-weight: 600;
  color: #2c3e50;
  margin-bottom: 15px;
  padding-bottom: 8px;
  border-bottom: 1px solid #ecf0f1;
}

.index-page .result-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.index-page .result-item {
  margin-bottom: 8px;
}

.index-page .result-link {
  display: flex;
  align-items: center;
  padding: 10px;
  text-decoration: none;
  color: #34495e;
  border-radius: 6px;
  transition: all 0.2s;
}

.index-page .result-link:hover {
  background-color: #f1f9ff;
}

.index-page .result-name {
  flex: 1;
  font-weight: 500;
}

.index-page .result-company {
  color: #7f8c8d;
  margin: 0 10px;
  font-size: 14px;
  font-style: italic;
}

.index-page .result-page {
  color: #3498db;
  font-weight: 600;
  font-size: 14px;
  min-width: 50px;
  text-align: right;
}

/* Responsividade */
@media (max-width: 768px) {
  .index-page .page-inner {
    padding: 15px;
  }
  
  .index-page .index-title {
    font-size: 22px;
  }
  
  .index-page .alphabet-nav {
    gap: 2px;
  }
  
  .index-page .letter-btn {
    width: 60px;
    height: 60px;
    font-size: 14px;
  }
}

.alphabet-nav {
  display: grid;
  width: 100%;   /* ocupa a largura toda */
  height: 100%;  /* ocupa a altura toda */

  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  grid-auto-rows: 1fr; /* altura das linhas iguais */
}

.tittle-index-products {
  font-size: 24px;
}

.span-index-products {
  font-size: 20px;
}