/* -------------------------------------------------- */
/* Catalogue-specific styles                          */
/* Loads AFTER ../css/site.css and uses its tokens    */
/* (--ink, --brand, --line, --wash, --radius, etc.)   */
/* -------------------------------------------------- */

/* ---- Breadcrumb (sits in the page header) -------------------------------- */

.page-head .breadcrumb {
  margin: 0 0 0.75rem;
  padding: 0;
  font-size: 0.95rem;
}
.page-head .breadcrumb-item,
.page-head .breadcrumb-item.active { color: var(--ink-soft); }
.page-head .breadcrumb-item a { color: var(--brand-dark); font-weight: 600; }
.page-head .breadcrumb-item + .breadcrumb-item::before { color: var(--ink-soft); }

/* ---- Catalogue home: department navigation ------------------------------- */

.list-group-item-action { cursor: pointer; }

.dept-nav {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.dept-nav .list-group-item {
  border: 0;
  border-top: 1px solid var(--line);
  border-radius: 0;
  padding: 0.85rem 1.1rem;
  font-weight: 600;
  color: var(--ink);
  background: transparent;
}
.dept-nav .list-group-item:first-child { border-top: 0; }
.dept-nav .list-group-item:hover,
.dept-nav .list-group-item:focus-visible { background: var(--wash); color: var(--brand-dark); }
.dept-nav .list-group-item.active,
.dept-nav .list-group-item-action.active {
  background-color: var(--ink) !important;
  border-color: var(--ink) !important;
  color: #fff !important;
}

.dept-panel { display: none; }
.dept-panel:first-of-type { display: block; }
.dept-panel h2 { margin-bottom: 1.1rem; }

.cat-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}
@media (max-width: 575.98px) { .cat-list { grid-template-columns: 1fr; } }

.cat-link {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  height: 100%;
  padding: 0.9rem 1.1rem;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
}
.cat-link i { color: var(--brand); font-size: 0.85rem; }
.cat-link:hover,
.cat-link:focus-visible {
  color: var(--brand-dark);
  border-color: var(--brand);
  box-shadow: inset 0 -3px 0 var(--brand);
}

/* ---- Category page: product list ------------------------------------------ */

.cat-item { padding: 1.6rem 0; border-bottom: 1px solid var(--line); }
.cat-item:first-child { border-top: 1px solid var(--line); }

.cat-item-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1.25rem;
  margin-bottom: 0.6rem;
}
.cat-item-head h2 { font-size: 1.3rem; line-height: 1.25; margin: 0; }

.cat-price {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--brand);
  white-space: nowrap;
}
.cat-gst {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0;
  color: var(--ink-soft);
}

.cat-item-body { display: flex; align-items: flex-start; gap: 1.75rem; }
.cat-item-main { flex: 1 1 auto; min-width: 0; }
.cat-item-media { flex: 0 0 auto; }

.cat-item-image {
  display: block;
  max-width: 180px;
  max-height: 180px;
  width: auto;
  height: auto;
  padding: 0.5rem;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.cat-desc { color: var(--ink-soft); max-width: 70ch; margin-bottom: 0.75rem; }
.cat-desc > :last-child { margin-bottom: 0; }
.cat-desc ul, .cat-desc ol { padding-left: 1.25rem; margin-bottom: 0.5rem; }

.cat-deal {
  display: inline-block;
  margin: 0 0 0.6rem;
  padding: 0.25rem 0.7rem;
  background: #fbe4e4;
  color: var(--brand-dark);
  border-radius: 6px;
  font-weight: 700;
}

.cat-avail { font-weight: 700; margin: 0 0 0.5rem; }
.cat-avail.instock { color: #166116; }
.cat-avail.onorder { color: #5b626b; }
.cat-avail.unavailable { color: #5b626b; }

.cat-plu { color: #5b626b; font-size: 0.88rem; margin: 0; }

/* Phones: image above the description, price stays beside the name */
@media (max-width: 575.98px) {
  .cat-item-body { flex-direction: column-reverse; gap: 1rem; }
  .cat-item-media { align-self: center; }
  .cat-item-head { gap: 0.75rem; }
  .cat-item-head h2 { font-size: 1.15rem; }
  .cat-price { text-align: right; line-height: 1.2; }
  .cat-gst { display: block; }
}

/* ---- Shared ---------------------------------------------------------------- */

.cat-disclaimer { color: var(--ink-soft); font-size: 0.9rem; margin: 1.75rem 0 0; max-width: 70ch; }
