/* Product catalogue (/products and product-category pages). */
.rxc {
  --rxc-accent: #f37021;
  --rxc-ink: #1c2733;
  --rxc-muted: #6b7680;
  --rxc-line: #e3e7eb;
  --rxc-soft: #f6f8fa;
  color: var(--rxc-ink);
  font-size: 15px;
  line-height: 1.5;
  margin: 0 auto 48px;
  max-width: 1280px;
  text-align: left;
  container-type: inline-size;
}
.rxc *, .rxc *::before, .rxc *::after { box-sizing: border-box; }
.rxc-title { font-size: 32px; line-height: 1.2; margin: 0 0 10px; color: var(--rxc-ink); }
.rxc-lede { color: var(--rxc-muted); margin: 0 0 20px; max-width: 900px; }
.rxc-lede p { margin: 0 0 8px; }

.rxc-search { display: flex; gap: 8px; margin: 0 0 28px; align-items: stretch; flex-wrap: wrap; }
.rxc .rxc-search input[type="search"] {
  flex: 1 1 260px;
  min-width: 0;
  height: 50px;
  margin: 0;
  padding: 0 16px;
  border: 1px solid #cfd6dc;
  border-radius: 6px;
  background: #fff;
  color: var(--rxc-ink);
  font-size: 16px;
  font-weight: 400;
  text-transform: none;
  letter-spacing: normal;
  line-height: normal;
  width: auto;
  box-shadow: none;
}
.rxc .rxc-search input[type="search"]::placeholder { color: #8a949d; opacity: 1; text-transform: none; letter-spacing: normal; font-size: 15px; }
.rxc .rxc-search input[type="search"]:focus { outline: none; border-color: var(--rxc-accent); box-shadow: 0 0 0 3px rgba(0, 0, 0, .06); }
.rxc .rxc-search button {
  flex: 0 0 auto;
  width: auto;
  min-width: 0;
  text-transform: none;
  height: 50px;
  margin: 0;
  padding: 0 28px;
  border: 0;
  border-radius: 6px;
  background: var(--rxc-accent);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: .3px;
  cursor: pointer;
  line-height: 50px;
}
.rxc .rxc-search button:hover { filter: brightness(.92); }
.rxc-clear { align-self: center; color: var(--rxc-muted); text-decoration: underline; font-size: 14px; padding: 0 6px; }

.rxc-layout { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 32px; align-items: start; }

.rxc-sidebar {
  border: 1px solid var(--rxc-line);
  border-radius: 8px;
  background: #fff;
  position: sticky;
  top: 20px;
  max-height: calc(100vh - 40px);
  overflow: auto;
}
.rxc-sidebar summary { list-style: none; cursor: default; padding: 16px 18px 10px; border-bottom: 1px solid var(--rxc-line); }
.rxc-sidebar summary::-webkit-details-marker { display: none; }
.rxc-sidebar h2 { display: inline; margin: 0; font-size: 18px; line-height: 1.3; color: var(--rxc-ink); text-transform: none; letter-spacing: 0; }
.rxc-sidebar ul { list-style: none; margin: 0; padding: 8px 0; }
.rxc-sidebar li { margin: 0; padding: 0; list-style: none; }
.rxc-sidebar li::before, .rxc-sidebar li::marker { content: none; display: none; }
.rxc-sidebar a {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 18px;
  color: var(--rxc-ink);
  font-size: 14px;
  line-height: 1.35;
  text-decoration: none;
  border-left: 3px solid transparent;
}
.rxc-sidebar a span { color: var(--rxc-muted); font-size: 12px; flex: 0 0 auto; padding-top: 1px; }
.rxc-sidebar a:hover { background: var(--rxc-soft); color: var(--rxc-accent); }
.rxc-sidebar a.is-active { border-left-color: var(--rxc-accent); background: var(--rxc-soft); color: var(--rxc-accent); font-weight: 700; }

.rxc-summary { margin: 0 0 16px; color: var(--rxc-muted); }
.rxc-summary strong { color: var(--rxc-ink); }

.rxc-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.rxc-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--rxc-line);
  border-radius: 8px;
  background: #fff;
  padding: 16px;
  color: var(--rxc-ink);
  text-decoration: none;
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.rxc-card:hover { border-color: var(--rxc-accent); box-shadow: 0 8px 22px rgba(20, 30, 40, .08); transform: translateY(-2px); color: var(--rxc-ink); text-decoration: none; }
.rxc-card-art {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 180px;
  margin: -4px -4px 14px;
  border-radius: 6px;
  background: var(--rxc-soft);
  overflow: hidden;
  color: #b5bec6;
}
.rxc-card-art img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; }
.rxc-card-art svg { width: 64px; height: 64px; }
.rxc-card-eyebrow { color: var(--rxc-accent); font-size: 11px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; margin-bottom: 4px; }
.rxc-card-title { font-size: 17px; line-height: 1.3; margin: 0 0 8px; color: var(--rxc-ink); text-transform: none; letter-spacing: 0; }
.rxc-card-partno { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; color: var(--rxc-ink); margin-bottom: 8px; }
.rxc-card-partno span { font-family: inherit; color: var(--rxc-muted); font-size: 11px; text-transform: uppercase; letter-spacing: .6px; margin-right: 4px; }
.rxc-card-excerpt {
  color: var(--rxc-muted);
  font-size: 14px;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.rxc-empty { border: 1px dashed #cfd6dc; border-radius: 8px; padding: 32px; text-align: center; color: var(--rxc-muted); }
.rxc-empty p { margin: 0 0 6px; }

.rxc-pager { margin-top: 32px; }
.rxc-pager .pager__items, .rxc-pager ul { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; list-style: none; margin: 0; padding: 0; }
.rxc-pager li { margin: 0; padding: 0; list-style: none; }
.rxc-pager li::before { content: none; }
.rxc-pager a {
  display: inline-block;
  min-width: 40px;
  padding: 8px 12px;
  border: 1px solid var(--rxc-line);
  border-radius: 6px;
  background: #fff;
  color: var(--rxc-ink);
  text-align: center;
  text-decoration: none;
  line-height: 1.2;
}
.rxc-pager a:hover { border-color: var(--rxc-accent); color: var(--rxc-accent); }
.rxc-pager .is-active a, .rxc-pager a[aria-current] { background: var(--rxc-accent); border-color: var(--rxc-accent); color: #fff; }
.rxc-pager .pager__item--ellipsis { padding: 8px 4px; color: var(--rxc-muted); }

/* Sized by the space the catalogue gets, not the viewport, so themes with
   their own sidebar still get a sensible grid. */
@container (max-width: 1000px) {
  .rxc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rxc-layout { grid-template-columns: 230px minmax(0, 1fr); gap: 24px; }
}
@container (max-width: 720px) {
  .rxc-layout { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .rxc-sidebar { position: static; max-height: none; }
  .rxc-sidebar summary { cursor: pointer; }
  .rxc-sidebar summary h2::after { content: " ▾"; color: var(--rxc-muted); }
  .rxc-sidebar ul { max-height: 320px; overflow: auto; }
  .rxc-title { font-size: 26px; }
}
@container (max-width: 480px) {
  .rxc-grid { grid-template-columns: minmax(0, 1fr); }
  .rxc .rxc-search button { flex: 1 1 100%; }
}
