/* BEEL Bags — public catalogue. Builds on styles.min.css (header, footer,
   .container, .page-header, .section-tag, colour variables). Phone first. */

.cat-page { background: #fff; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---- Header area ---- */
.cat-header { text-align: center; padding-bottom: 24px; }
.cat-header h1 { font-size: clamp(1.6rem, 4.5vw, 2.3rem); line-height: 1.2; }
.cat-header .cat-lead { max-width: 680px; margin: 8px auto 0; }
.cat-crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 4px 6px; justify-content: center; padding: 0; margin: 0 0 14px; font-size: .82rem; color: var(--color-text-muted, #94a3b8); }
.cat-crumbs li + li::before { content: "›"; margin-right: 6px; color: #cbd5e1; }
.cat-crumbs a { color: var(--color-text-secondary, #475569); text-decoration: none; }
.cat-crumbs a:hover { color: var(--color-primary, #1e3a8a); text-decoration: underline; }
.cat-crumbs [aria-current] { color: var(--color-text, #1e293b); font-weight: 600; overflow: hidden; text-overflow: ellipsis; max-width: 60vw; white-space: nowrap; }
.cat-product .cat-crumbs ol { justify-content: flex-start; }

/* ---- Buttons ---- */
.cat-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 18px; }
.cat-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 16px; border-radius: 999px;
  border: 1px solid #cbd5e1; background: #fff; color: var(--color-text, #1e293b);
  font: 600 .92rem/1 var(--font-body, Inter, sans-serif); text-decoration: none; cursor: pointer;
  transition: background .15s, border-color .15s, transform .1s;
}
.cat-btn:hover { border-color: var(--color-primary-light, #2563eb); color: var(--color-primary, #1e3a8a); }
.cat-btn:active { transform: scale(.98); }
.cat-btn-primary { background: var(--color-primary, #1e3a8a); border-color: var(--color-primary, #1e3a8a); color: #fff; }
.cat-btn-primary:hover { background: var(--color-primary-light, #2563eb); color: #fff; }
.cat-btn-wa { background: #25d366; border-color: #25d366; color: #063f1c; }
.cat-btn-wa:hover { background: #1fbe5b; border-color: #1fbe5b; color: #063f1c; }
.cat-btn-lg { min-height: 52px; font-size: 1rem; padding: 0 22px; }
.cat-btn.is-done { border-color: #16a34a; color: #16a34a; }

/* ---- Sections ---- */
.cat-section { padding: 28px 0; }
.cat-h2 { font-size: 1.35rem; margin: 0 0 14px; }
.cat-empty { text-align: center; color: var(--color-text-secondary, #475569); padding: 28px 0; }

/* ---- Category tiles ---- */
.cat-cat-grid { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cat-cat-grid a { display: flex; flex-direction: column; height: 100%; text-decoration: none; color: inherit; border: 1px solid #e2e8f0; border-radius: 14px; overflow: hidden; background: #fff; transition: box-shadow .2s, border-color .2s; }
.cat-cat-grid a:hover { border-color: #bfdbfe; box-shadow: 0 8px 24px rgba(30,58,138,.10); }
.cat-cat-name { font-family: var(--font-heading, Outfit, sans-serif); font-weight: 700; padding: 10px 12px 0; line-height: 1.25; }
.cat-cat-count { font-size: .8rem; color: var(--color-text-secondary, #475569); padding: 2px 12px 12px; }

/* ---- Filter bar ---- */
.cat-filter { position: sticky; top: 64px; z-index: 5; background: rgba(255,255,255,.96); backdrop-filter: blur(6px); padding: 10px 0; margin-bottom: 8px; border-bottom: 1px solid #f1f5f9; }
.cat-chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; -webkit-overflow-scrolling: touch; }
.cat-chips::-webkit-scrollbar { display: none; }
.cat-chips-links { margin-bottom: 18px; }
.cat-chip { flex: none; display: inline-flex; align-items: center; min-height: 38px; padding: 0 14px; border-radius: 999px; border: 1px solid #e2e8f0; background: #fff; color: var(--color-text, #1e293b); font: 600 .85rem var(--font-body, Inter, sans-serif); white-space: nowrap; text-decoration: none; cursor: pointer; }
.cat-chip:hover { border-color: #93c5fd; }
.cat-chip.is-active { background: var(--color-primary, #1e3a8a); border-color: var(--color-primary, #1e3a8a); color: #fff; }
.cat-search { display: block; margin-top: 10px; }
.cat-search input { width: 100%; min-height: 46px; padding: 0 16px; border: 1px solid #cbd5e1; border-radius: 999px; font: 16px var(--font-body, Inter, sans-serif); background: #fff; }
.cat-search input:focus { outline: 2px solid var(--color-primary-light, #2563eb); outline-offset: 1px; }

/* ---- Product groups & cards ---- */
.cat-group { margin-top: 22px; }
.cat-group-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.cat-group-head h3 { font-size: 1.1rem; margin: 0; }
.cat-group-head h3 a { color: inherit; text-decoration: none; }
.cat-more { font-size: .85rem; font-weight: 600; white-space: nowrap; color: var(--color-primary-light, #2563eb); text-decoration: none; }
.cat-grid { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cat-card a { display: flex; flex-direction: column; height: 100%; text-decoration: none; color: inherit; border: 1px solid #e2e8f0; border-radius: 14px; overflow: hidden; background: #fff; transition: box-shadow .2s, border-color .2s; }
.cat-card a:hover { border-color: #bfdbfe; box-shadow: 0 8px 24px rgba(30,58,138,.10); }
.cat-card-img { display: block; aspect-ratio: 1 / 1; overflow: hidden; min-height: 0; background: #f8fafc; padding: 10px; }
.cat-card-img img { width: 100%; height: 100%; object-fit: contain; display: block; }
.cat-card-body { display: flex; flex-direction: column; gap: 4px; padding: 10px 12px 12px; }
.cat-card-name { font-weight: 600; font-size: .92rem; line-height: 1.3; }
.cat-card-meta { font-size: .75rem; color: var(--color-text-secondary, #475569); }
.cat-card[hidden], .cat-group[hidden] { display: none; }

/* ---- Product page ---- */
.cat-product { padding-top: 92px; }
.cat-pd { display: grid; gap: 22px; }
.cat-gallery { position: relative; min-width: 0; }
.cat-gallery-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; border-radius: 16px; background: #f8fafc; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.cat-gallery-track::-webkit-scrollbar { display: none; }
.cat-gallery-track:focus-visible { outline: 2px solid var(--color-primary-light, #2563eb); }
.cat-slide { flex: 0 0 100%; scroll-snap-align: center; margin: 0; aspect-ratio: 1 / 1; padding: 14px; display: flex; align-items: center; justify-content: center; }
.cat-slide img { width: 100%; height: 100%; object-fit: contain; }
.cat-gallery-nav { position: absolute; top: calc(50% - 46px); width: 40px; height: 40px; border-radius: 50%; border: 1px solid #e2e8f0; background: rgba(255,255,255,.92); font-size: 1.6rem; line-height: 1; color: var(--color-primary, #1e3a8a); cursor: pointer; display: none; }
.cat-gallery-nav.prev { left: 8px; } .cat-gallery-nav.next { right: 8px; }
.cat-thumbs { display: flex; gap: 8px; overflow-x: auto; margin-top: 10px; scrollbar-width: none; }
.cat-thumbs::-webkit-scrollbar { display: none; }
.cat-thumb { flex: none; width: 64px; height: 64px; border-radius: 10px; border: 2px solid #e2e8f0; background: #f8fafc; padding: 4px; }
.cat-thumb img { width: 100%; height: 100%; object-fit: contain; display: block; }
.cat-thumb.is-active { border-color: var(--color-primary, #1e3a8a); }
.cat-pd-info h1 { font-size: clamp(1.5rem, 4vw, 2.1rem); line-height: 1.2; margin: 6px 0 8px; }
.cat-pd-info .section-tag { text-decoration: none; margin-bottom: 4px; }
.cat-price { display: inline-block; font-weight: 700; color: var(--color-primary, #1e3a8a); background: #eff6ff; border: 1px solid #bfdbfe; padding: 6px 14px; border-radius: 999px; margin: 4px 0 10px; }
.cat-moq { color: var(--color-text-secondary, #475569); margin: 0 0 12px; }
.cat-desc { margin: 0 0 16px; line-height: 1.6; }
.cat-enquire { display: grid; gap: 10px; margin: 16px 0 18px; }
.cat-specs { margin: 0; border-top: 1px solid #e2e8f0; }
.cat-specs div { display: grid; grid-template-columns: 130px 1fr; gap: 12px; padding: 10px 0; border-bottom: 1px solid #f1f5f9; }
.cat-specs dt { font-weight: 600; color: var(--color-text-secondary, #475569); font-size: .9rem; }
.cat-specs dd { margin: 0; }
.cat-share-small { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; margin-top: 16px; font-size: .9rem; color: var(--color-text-secondary, #475569); }
.cat-share-small a, .cat-share-small button { color: var(--color-primary-light, #2563eb); font: 600 .9rem var(--font-body, Inter, sans-serif); background: none; border: 0; padding: 6px 0; cursor: pointer; text-decoration: none; }
.cat-related { padding-top: 8px; }

/* ---- Bottom CTA ---- */
.cat-cta { padding: 12px 0 40px; }
.cat-cta-box { display: grid; gap: 16px; padding: 22px; border-radius: 18px; background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%); color: #fff; }
.cat-cta-box h2 { color: #fff; margin: 0 0 4px; font-size: 1.3rem; }
.cat-cta-box p { margin: 0; color: #dbeafe; }
.cat-cta-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.cat-cta-actions .cat-btn:not(.cat-btn-wa) { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); }

/* ---- Larger screens ---- */
@media (min-width: 640px) {
  .cat-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
  .cat-cat-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
  .cat-enquire { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 900px) {
  .cat-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .cat-cat-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .cat-filter { display: flex; align-items: center; gap: 16px; top: 72px; }
  .cat-filter .cat-chips { flex: 1; min-width: 0; }
  .cat-search { margin-top: 0; width: 300px; flex: none; }
  .cat-pd { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 40px; align-items: start; }
  .cat-gallery { position: sticky; top: 90px; }
  .cat-gallery-nav { display: block; }
  .cat-cta-box { grid-template-columns: 1fr auto; align-items: center; padding: 28px 32px; }
}

/* ---- YouTube videos (product page) ---- */
.cat-videos { padding-top: 0; }
.cat-video-grid { display: grid; gap: 14px; grid-template-columns: 1fr; }
.cat-video { position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; border: 0; padding: 0; border-radius: 14px; overflow: hidden; background: #000; cursor: pointer; }
.cat-video.is-vertical { aspect-ratio: 9 / 16; max-width: 360px; justify-self: center; }
.cat-video img { width: 100%; height: 100%; object-fit: cover; opacity: .92; transition: opacity .2s; }
.cat-video:hover img { opacity: 1; }
.cat-play { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.cat-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
@media (min-width: 900px) { .cat-video-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; } }
