/* Solnac Bearings — catálogo completo de referencias */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.catalog-hero {
  max-width: var(--container);
  margin: 0 auto;
  padding: clamp(2.5rem, 6vw, 4rem) clamp(1.25rem, 5vw, 3rem) 1.5rem;
  text-align: center;
}

.catalog-hero h1 {
  font-size: clamp(1.9rem, 3.6vw, 2.6rem);
  max-width: 820px;
  margin: 0 auto 0.7em;
}

.catalog-hero p {
  max-width: 680px;
  margin: 0 auto 1.6rem;
}

.catalog-hero .hero-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.catalog-search-bar {
  position: sticky;
  top: 68px;
  z-index: 40;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0.9rem clamp(1.25rem, 5vw, 3rem);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  gap: 1rem;
}

#catalog-search {
  flex: 1;
  font-family: "Inter", sans-serif;
  font-size: 0.95rem;
  padding: 0.75rem 1.1rem;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  outline: none;
  background: var(--white);
  color: var(--ink);
}

#catalog-search:focus { border-color: var(--blue-500); }

.catalog-search-count {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
}

.catalog-toc {
  max-width: var(--container);
  margin: 0 auto;
  padding: 1.6rem clamp(1.25rem, 5vw, 3rem) 0.5rem;
}

.catalog-toc ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.catalog-toc a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--navy-800);
  background: var(--blue-50);
  border: 1px solid var(--line);
  padding: 0.5rem 0.9rem;
  border-radius: 999px;
  transition: background 0.2s ease, color 0.2s ease;
}

.catalog-toc a:hover { background: var(--blue-100); color: var(--blue-700); }

.catalog-toc a span {
  background: var(--white);
  color: var(--blue-600);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.1rem 0.5rem;
  border-radius: 999px;
}

.catalog-list {
  max-width: var(--container);
  margin: 0 auto;
  padding: 1rem clamp(1.25rem, 5vw, 3rem) 2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.cat-block {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  overflow: hidden;
  scroll-margin-top: 130px;
}

.cat-block summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem 1.5rem;
  background: var(--blue-50);
}

.cat-block summary::-webkit-details-marker { display: none; }

.cat-block summary h2 {
  font-size: 1.05rem;
  margin: 0;
}

.cat-block summary::after {
  content: "+";
  font-size: 1.3rem;
  color: var(--blue-600);
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.cat-block[open] summary::after { transform: rotate(45deg); }

.cat-count {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--blue-600);
  background: var(--white);
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  white-space: nowrap;
}

.cat-table-wrap {
  overflow-x: auto;
}

.cat-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.cat-table th {
  text-align: left;
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  padding: 0.7rem 1.2rem;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.cat-table td {
  padding: 0.65rem 1.2rem;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  vertical-align: top;
}

.cat-table td:first-child {
  font-weight: 700;
  color: var(--navy-900);
  white-space: nowrap;
}

.cat-table tr:last-child td { border-bottom: none; }
.cat-table tr:hover td { background: var(--blue-50); }

.cat-table tr[hidden] { display: none; }

.cat-block[data-empty="true"] { display: none; }

@media (max-width: 720px) {
  .catalog-search-bar { top: 0; }
  .cat-table { font-size: 0.82rem; }
  .cat-table th:nth-child(3), .cat-table td:nth-child(3) { display: none; }
}
