/* ==========================================================================
   SFX Fasteners — main.css
   Lightweight industrial-retail hybrid stylesheet.
   No framework, no jQuery dependency. Mobile first.
   ========================================================================== */

:root {
  --ink: #0b1b2b;
  --ink-soft: #24384c;
  --muted: #64748b;
  --muted-2: #94a3b8;
  --line: #e3e8ee;
  --line-strong: #cbd5e1;
  --bg: #ffffff;
  --bg-alt: #f6f8fa;
  --bg-sunken: #eef2f6;

  --brand: #003e88;
  --brand-dark: #002b64;
  --brand-tint: #e9eff9;
  --accent: #e8590c;
  --accent-tint: #fdf1e8;
  --green: #12805c;
  --green-tint: #e8f5f0;
  --red: #c0392b;

  --radius: 10px;
  --radius-sm: 6px;
  --radius-lg: 16px;
  --wrap: 1240px;
  --gap: 20px;

  --shadow-sm: 0 1px 2px rgba(11, 27, 43, .06);
  --shadow: 0 2px 10px rgba(11, 27, 43, .07);
  --shadow-lg: 0 12px 32px rgba(11, 27, 43, .12);

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-num: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-dark); }
button { font: inherit; cursor: pointer; }
ul { margin: 0; padding: 0; list-style: none; }

h1, h2, h3, h4 { margin: 0 0 .5em; line-height: 1.25; letter-spacing: -.02em; font-weight: 700; }
h1 { font-size: 34px; }
h2 { font-size: 24px; }
h3 { font-size: 17px; }
p { margin: 0 0 1em; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.section { padding: 56px 0; }
.section--alt { background: var(--bg-alt); }
.section--tight { padding: 36px 0; }

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

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 20px; border-radius: var(--radius-sm); border: 1px solid transparent;
  font-size: 14px; font-weight: 600; line-height: 1.2; text-align: center;
  transition: background .15s, border-color .15s, color .15s, transform .1s;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--brand); color: #fff; }
.btn--primary:hover { background: var(--brand-dark); color: #fff; }
.btn--accent { background: var(--accent); color: #fff; }
.btn--accent:hover { background: #c94a08; color: #fff; }
.btn--ghost { border-color: var(--line-strong); color: var(--ink); background: #fff; }
.btn--ghost:hover { border-color: var(--brand); color: var(--brand); }
.btn--block { width: 100%; }
.btn--sm { padding: 9px 14px; font-size: 13px; }
.btn--lg { padding: 15px 28px; font-size: 15px; }

/* ---------- badges & chips ---------- */
.badge {
  display: inline-block; padding: 3px 9px; border-radius: 999px;
  font-size: 12px; font-weight: 600; line-height: 1.5; white-space: nowrap;
}
.badge--stock { background: var(--green-tint); color: var(--green); }
.badge--low { background: var(--accent-tint); color: var(--accent); }
.badge--out { background: #f1f5f9; color: var(--muted); }
.badge--wholesale { background: var(--accent); color: #fff; }
.badge--std { background: var(--brand-tint); color: var(--brand); }

.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  display: inline-block; padding: 4px 10px; border: 1px solid var(--line);
  border-radius: 999px; font-size: 12px; color: var(--muted); background: #fff;
}
.chip--solid { background: var(--bg-sunken); border-color: transparent; color: var(--ink-soft); }

/* ---------- header ---------- */
.hdr { position: sticky; top: 0; z-index: 60; background: #fff; border-bottom: 1px solid var(--line); }
.hdr__main { display: flex; align-items: center; gap: 18px; min-height: 72px; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 19px; letter-spacing: -.03em; color: var(--ink); }
.logo:hover { color: var(--brand); }
.logo__mark {
  width: 34px; height: 34px; border-radius: 8px; background: var(--brand);
  color: #fff; display: grid; place-items: center; font-size: 15px; font-weight: 800; letter-spacing: -.04em;
}
.logo__text { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; }
.logo__name { font-size: 20px; font-weight: 800; letter-spacing: -.03em; line-height: 1.12; color: var(--ink); white-space: nowrap; }
.logo__sub {
  width: 100%; font-size: 8.5px; font-weight: 600; color: var(--muted); letter-spacing: 0;
  line-height: 1.35; white-space: nowrap; text-align: justify; text-align-last: justify;
  margin-top: 1px;
}

/* Scoped to the header form on purpose: WordPress puts a bare "search" class
   on <body> for ?s= results, so an unqualified .search rule used to clamp the
   whole results page to 520px. */
form.search { flex: 1 1 auto; max-width: 520px; display: flex; }
form.search input {
  flex: 1 1 auto; width: auto; min-width: 0; padding: 11px 14px; border: 1px solid var(--line-strong);
  border-right: 0; border-radius: var(--radius-sm) 0 0 var(--radius-sm); font-size: 14px; color: var(--ink); background: #fff;
}
form.search input:focus { outline: 2px solid var(--brand-tint); border-color: var(--brand); position: relative; z-index: 1; }
form.search .search__btn {
  flex: none; padding: 0 18px; border: 1px solid var(--brand); background: var(--brand); color: #fff;
  font-size: 13.5px; font-weight: 600; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; cursor: pointer;
}
form.search .search__btn:hover { filter: brightness(1.12); }

.hdr__actions { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.iconbtn {
  display: flex; align-items: center; gap: 8px; padding: 9px 12px; border-radius: var(--radius-sm);
  border: 1px solid transparent; background: transparent; color: var(--ink-soft); font-size: 13px; font-weight: 600;
}
.iconbtn:hover { background: var(--bg-alt); color: var(--brand); }
.iconbtn svg { width: 19px; height: 19px; flex: none; }
.iconbtn__count {
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--accent);
  color: #fff; font-size: 11px; display: grid; place-items: center; font-weight: 700;
}

/* category navigation strip */
.catnav { border-top: 1px solid var(--line); background: #fff; }
.catnav .wrap { display: flex; align-items: center; gap: 4px; }
@media (max-width: 1099px) {
  /* narrow screens keep the horizontal scroller; desktop must not clip the mega panel */
  .catnav .wrap { overflow-x: auto; scrollbar-width: none; }
  .catnav .wrap::-webkit-scrollbar { display: none; }
}
.catnav__all {
  display: flex; align-items: center; gap: 8px; padding: 13px 16px; background: var(--brand); color: #fff;
  font-size: 14px; font-weight: 600; border-radius: 0; white-space: nowrap;
}
.catnav__all:hover { background: var(--brand-dark); color: #fff; }
.catnav a.catnav__link {
  padding: 13px 12px; font-size: 13.5px; font-weight: 500; color: var(--ink-soft); white-space: nowrap; border-bottom: 2px solid transparent;
}
.catnav a.catnav__link:hover { color: var(--brand); border-bottom-color: var(--brand); }

/* ---------- hero ---------- */
.hero { background: linear-gradient(180deg, #f7fafc 0%, #eef4f9 100%); border-bottom: 1px solid var(--line); }
.hero__grid { display: grid; grid-template-columns: 1fr; gap: 34px; padding: 44px 0; align-items: center; }
.hero h1 { font-size: 38px; margin-bottom: 14px; }
.hero p.lead { font-size: 17px; color: var(--ink-soft); max-width: 46ch; margin-bottom: 22px; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 22px; }
.hero__points { display: flex; flex-wrap: wrap; gap: 10px 22px; font-size: 13.5px; color: var(--ink-soft); }
.hero__points li { display: flex; align-items: center; gap: 7px; }
.tick { color: var(--green); font-weight: 700; }

.hero__panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 22px; box-shadow: var(--shadow); }
.hero__panel h3 { font-size: 15px; margin-bottom: 4px; }
.hero__panel .sub { font-size: 13px; color: var(--muted); margin-bottom: 16px; }
.tiles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.tile {
  display: flex; flex-direction: column; gap: 4px; padding: 13px; border: 1px solid var(--line);
  border-radius: var(--radius-sm); background: var(--bg-alt);
}
.tile:hover { border-color: var(--brand); background: #fff; }
.tile__name { font-size: 13.5px; font-weight: 600; color: var(--ink); }
.tile__count { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }

/* ---------- trust bar ---------- */
.trust { border-bottom: 1px solid var(--line); background: #fff; }
.trust .wrap { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; padding: 22px 20px; }
.trust__item { display: flex; gap: 12px; align-items: flex-start; }
.trust__icon {
  width: 38px; height: 38px; flex: none; border-radius: 9px; background: var(--brand-tint);
  color: var(--brand); display: grid; place-items: center; font-size: 15px; font-weight: 800;
}
.trust__t { font-size: 14px; font-weight: 600; }
.trust__d { font-size: 12.5px; color: var(--muted); }

/* ---------- section head ---------- */
.sechead { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 24px; }
.sechead p { margin: 6px 0 0; color: var(--muted); font-size: 14px; max-width: 62ch; }
.sechead a.more { font-size: 13.5px; font-weight: 600; white-space: nowrap; }

/* ---------- category grid ---------- */
.catgrid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.catcard {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 15px 16px;
  border: 1px solid var(--line); border-radius: var(--radius); background: #fff; transition: .15s;
}
.catcard:hover { border-color: var(--brand); box-shadow: var(--shadow-sm); transform: translateY(-1px); }
.catcard__name { font-size: 14px; font-weight: 600; color: var(--ink); }
.catcard__n { display: block; font-size: 12px; color: var(--muted); font-weight: 500; font-variant-numeric: tabular-nums; }
.catcard__go { color: var(--muted-2); font-size: 17px; line-height: 1; }

/* ---------- product grid & cards ---------- */
.pgrid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.pcard {
  display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden; transition: .15s;
}
.pcard:hover { border-color: var(--line-strong); box-shadow: var(--shadow); }
.pcard__media { position: relative; background: var(--bg-alt); aspect-ratio: 1 / 1; display: grid; place-items: center; overflow: hidden; }
.pcard__media img { width: 100%; height: 100%; object-fit: cover; }
.pcard__flag { position: absolute; top: 10px; left: 10px; }
.pcard__body { padding: 14px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.pcard__title { font-size: 14px; font-weight: 600; line-height: 1.4; color: var(--ink); margin: 0; }
.pcard__title a { color: inherit; }
.pcard__meta { font-size: 12px; color: var(--muted); font-family: var(--font-num); }
.pcard__foot { margin-top: auto; display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; padding-top: 6px; }
.price { font-size: 17px; font-weight: 700; letter-spacing: -.02em; }
.price small { display: block; font-size: 12px; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.price__range { font-size: 12px; color: var(--muted); font-weight: 500; }
.pcard__actions { display: flex; gap: 8px; margin-top: 10px; }
.pcard__actions .btn { flex: 1; }

/* ---------- wholesale band ---------- */
.wholesale { background: var(--ink); color: #e2e8f0; }
.wholesale h2 { color: #fff; }
.wholesale p { color: #a8b8c9; }
.wholesale__grid { display: grid; grid-template-columns: 1fr; gap: 30px; align-items: start; }
.tiers { width: 100%; border-collapse: collapse; background: #fff; border-radius: var(--radius); overflow: hidden; color: var(--ink); }
.tiers th, .tiers td { padding: 12px 14px; text-align: left; font-size: 13.5px; border-bottom: 1px solid var(--line); }
.tiers th { background: var(--bg-sunken); font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); font-weight: 700; }
.tiers td:last-child, .tiers th:last-child { text-align: right; font-variant-numeric: tabular-nums; }
.tiers tr:last-child td { border-bottom: 0; }
.tiers .locked { color: var(--muted-2); }

/* ---------- services ---------- */
.svcgrid { display: grid; grid-template-columns: 1fr; gap: 14px; }
.svccard { padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.svccard h3 { font-size: 15.5px; margin-bottom: 6px; }
.svccard p { font-size: 13.5px; color: var(--muted); margin: 0; }
.svccard__n { font-family: var(--font-num); font-size: 12px; color: var(--brand); font-weight: 700; }

/* ---------- stats ---------- */
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.stat { background: #fff; padding: 20px 18px; }
.stat__n { font-size: 28px; font-weight: 800; letter-spacing: -.03em; color: var(--brand); font-variant-numeric: tabular-nums; }
.stat__l { font-size: 12.5px; color: var(--muted); }

/* ---------- guides / articles ---------- */
.guides { display: grid; grid-template-columns: 1fr; gap: 14px; }
.guide { display: flex; gap: 14px; padding: 16px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.guide__tag { font-size: 11.5px; font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: .05em; }
.guide h3 { font-size: 15px; margin: 4px 0 6px; }
.guide p { font-size: 13px; color: var(--muted); margin: 0; }

/* ---------- footer ---------- */
.ftr { background: var(--ink); color: #9fb1c4; padding: 46px 0 0; font-size: 13.5px; }
.ftr a { color: #9fb1c4; }
.ftr a:hover { color: #fff; }
.ftr__grid { display: grid; grid-template-columns: 1fr; gap: 28px; padding-bottom: 34px; }
.ftr h4 { color: #fff; font-size: 14px; margin-bottom: 12px; }
.ftr li { margin-bottom: 8px; }
.ftr__grid > div > a { display: block; margin-bottom: 8px; }
.ftr__brand p { font-size: 13px; color: #8fa3b8; }
.ftr__bottom { border-top: 1px solid rgba(255,255,255,.1); padding: 16px 0; display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; font-size: 12.5px; color: #7f94a9; }
.paylist { display: flex; gap: 8px; flex-wrap: wrap; }
.paylist span { padding: 4px 9px; border: 1px solid rgba(255,255,255,.18); border-radius: 5px; font-size: 11.5px; }

/* ---------- breadcrumbs ---------- */
.crumbs { font-size: 12.5px; color: var(--muted); padding: 14px 0; }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--brand); }
.crumbs span { margin: 0 7px; color: var(--muted-2); }

/* ---------- product detail ---------- */
.pdp { display: grid; grid-template-columns: 1fr; gap: 30px; padding-bottom: 20px; }
.gallery__main { border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-alt); aspect-ratio: 1/1; display: grid; place-items: center; overflow: hidden; }
.gallery__thumbs { display: flex; gap: 8px; margin-top: 10px; }
.gallery__thumbs div { width: 64px; height: 64px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--bg-alt); overflow: hidden; }
.gallery__thumbs div.is-active { border-color: var(--brand); }

.pdp__title { font-size: 26px; margin-bottom: 10px; }
.pdp__sku { font-size: 12.5px; color: var(--muted); font-family: var(--font-num); margin-bottom: 14px; }
.pricebox { display: flex; align-items: baseline; gap: 12px; padding: 16px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.pricebox .price { font-size: 26px; }
.pricebox__note { font-size: 12.5px; color: var(--muted); }

.buybox { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; margin: 18px 0; }
.qty { display: flex; align-items: center; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); overflow: hidden; }
.qty button { width: 38px; height: 44px; border: 0; background: #fff; font-size: 17px; color: var(--ink-soft); }
.qty input { width: 62px; height: 44px; border: 0; border-left: 1px solid var(--line); border-right: 1px solid var(--line); text-align: center; font-size: 14px; font-variant-numeric: tabular-nums; }
.qty input:focus { outline: none; }

.notice { display: flex; gap: 12px; padding: 13px 15px; border-radius: var(--radius-sm); font-size: 13px; margin: 14px 0; }
.notice--info { background: var(--brand-tint); color: var(--brand-dark); }
.notice--accent { background: var(--accent-tint); color: #8a3a09; }
.notice--green { background: var(--green-tint); color: #0b5c43; }
.notice strong { font-weight: 700; }

.specs { width: 100%; border-collapse: collapse; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.specs th, .specs td { padding: 11px 14px; font-size: 13.5px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.specs th { width: 38%; background: var(--bg-alt); font-weight: 600; color: var(--ink-soft); }
.specs tr:last-child th, .specs tr:last-child td { border-bottom: 0; }

.panel { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.panel__head { padding: 14px 18px; border-bottom: 1px solid var(--line); font-weight: 700; font-size: 15px; }
.panel__body { padding: 18px; }
.panel + .panel { margin-top: 16px; }

.acc { border-top: 1px solid var(--line); }
.acc__item { border-bottom: 1px solid var(--line); }
.acc__btn { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 15px 2px; background: none; border: 0; text-align: left; font-size: 14px; font-weight: 600; color: var(--ink); }
.acc__btn i { font-style: normal; color: var(--muted-2); transition: transform .18s; }
.acc__item.is-open .acc__btn i { transform: rotate(45deg); }
.acc__body { display: none; padding: 0 2px 16px; font-size: 13.5px; color: var(--ink-soft); }
.acc__item.is-open .acc__body { display: block; }

.rail { display: flex; flex-direction: column; gap: 14px; }

/* ---------- filters (archive) ---------- */
.listing { display: grid; grid-template-columns: 1fr; gap: 24px; }
.filters { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.filters__head { padding: 14px 16px; border-bottom: 1px solid var(--line); font-weight: 700; font-size: 14px; display: flex; justify-content: space-between; align-items: center; }
.fgroup { padding: 14px 16px; border-bottom: 1px solid var(--line); }
.fgroup:last-child { border-bottom: 0; }
.fgroup h4 { font-size: 13px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin-bottom: 10px; }
.fgroup label { display: flex; align-items: center; gap: 9px; font-size: 13.5px; margin-bottom: 8px; color: var(--ink-soft); }
.fgroup label:last-child { margin-bottom: 0; }
.fgroup .n { margin-left: auto; font-size: 12px; color: var(--muted-2); font-variant-numeric: tabular-nums; }

.toolbar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; padding: 12px 16px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; margin-bottom: 16px; font-size: 13.5px; }
.toolbar select { padding: 8px 10px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); font-size: 13.5px; background: #fff; }

/* ---------- forms ---------- */
.form { display: grid; gap: 14px; }
.field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; color: var(--ink-soft); }
.field input, .field select, .field textarea {
  width: 100%; padding: 11px 13px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm);
  font-size: 14px; font-family: inherit; color: var(--ink); background: #fff;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--brand-tint); border-color: var(--brand); }
.field__hint { font-size: 12px; color: var(--muted); margin-top: 5px; }
.grid-2 { display: grid; grid-template-columns: 1fr; gap: 14px; }
.axis { border: 1px dashed var(--line-strong); border-radius: var(--radius); padding: 22px; text-align: center; background: var(--bg-alt); }
.axis strong { display: block; font-size: 14px; margin-bottom: 4px; }
.axis span { font-size: 12.5px; color: var(--muted); }

.steps { display: grid; grid-template-columns: 1fr; gap: 14px; counter-reset: s; }
.step { position: relative; padding: 18px 18px 18px 58px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.step::before {
  counter-increment: s; content: counter(s);
  position: absolute; left: 18px; top: 18px; width: 26px; height: 26px; border-radius: 50%;
  background: var(--brand); color: #fff; display: grid; place-items: center; font-size: 13px; font-weight: 700;
}
.step h3 { font-size: 15px; margin-bottom: 4px; }
.step p { font-size: 13.5px; color: var(--muted); margin: 0; }

/* ---------- floating enquiry bar ---------- */
.fab {
  position: fixed; right: 18px; bottom: 18px; z-index: 70; display: flex; flex-direction: column; gap: 10px;
}
.fab a {
  display: flex; align-items: center; gap: 9px; padding: 12px 16px; border-radius: 999px;
  background: var(--brand); color: #fff; font-size: 13.5px; font-weight: 600; box-shadow: var(--shadow-lg);
}
.fab a.alt { background: var(--accent); }
.fab a:hover { color: #fff; }

/* ---------- responsive ---------- */
@media (min-width: 640px) {
  .catgrid { grid-template-columns: repeat(3, 1fr); }
  .pgrid { grid-template-columns: repeat(3, 1fr); }
  .svcgrid { grid-template-columns: repeat(2, 1fr); }
  .grid-2 { grid-template-columns: 1fr 1fr; }
  .stats { grid-template-columns: repeat(4, 1fr); }
  .trust .wrap { grid-template-columns: repeat(4, 1fr); }
  .guides { grid-template-columns: repeat(3, 1fr); }
  .ftr__grid { grid-template-columns: 2fr 1fr 1fr 1fr; }
  .steps { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 900px) {
  .hero__grid { grid-template-columns: 1.15fr .85fr; padding: 56px 0; }
  .pgrid { grid-template-columns: repeat(4, 1fr); }
  .catgrid { grid-template-columns: repeat(4, 1fr); }
  .wholesale__grid { grid-template-columns: 1fr 1.1fr; gap: 44px; }
  .pdp { grid-template-columns: 1.05fr .95fr; gap: 40px; }
  .listing { grid-template-columns: 258px 1fr; gap: 28px; }
  .svcgrid { grid-template-columns: repeat(4, 1fr); }
  .steps { grid-template-columns: repeat(4, 1fr); }
  .section { padding: 68px 0; }
}

@media (min-width: 1100px) {
  .pdp { grid-template-columns: 1.1fr .9fr 250px; }
}

@media (max-width: 899px) {
  .catnav .wrap { padding: 0; }
  .hdrmobile-hide { display: none; }
  .hero h1 { font-size: 29px; }
  .fab { right: 12px; bottom: 12px; }
  .fab a span { display: none; }
  .fab a { padding: 14px; }
}

/* --- Primary nav menu rendered by wp_nav_menu inside the category strip --- */
.catnav ul.catnav__list { display: flex; align-items: stretch; gap: 2px; list-style: none; margin: 0; padding: 0; }
.catnav ul.catnav__list li { margin: 0; padding: 0; }
.catnav ul.catnav__list li a { display: block; padding: 11px 13px; font-size: 14px; font-weight: 500; color: var(--ink); border-bottom: 2px solid transparent; white-space: nowrap; line-height: 1.2; }
.catnav ul.catnav__list li a:hover { color: var(--brand); border-bottom-color: var(--brand); }
@media (max-width: 760px) {
  .catnav ul.catnav__list li a { padding: 10px 10px; font-size: 13px; }
}

/* ---- volume discount ladder (public, order-subtotal based) ---- */
.badge--off { background: var(--green-tint); color: var(--green); font-weight: 700; }
.tiers .is-base td { color: var(--muted); }
.tiers-panel .panel__head { display: flex; align-items: center; gap: 8px; }
.sfx-volume-notice { margin: 0 0 18px; }
.sfx-volume-notice strong { margin-right: 6px; }
.pricebox__note .sfx-save { color: var(--green); font-weight: 700; }

/* ---- category strip: real product categories appended after the utility menu ---- */
.catnav ul.catnav__list li.catnav__cat.is-first-cat { margin-left: 10px; padding-left: 10px; border-left: 1px solid var(--line); }
.catnav ul.catnav__list li.catnav__cat a { font-weight: 600; }

/* ---- standard matrix page (DIN 933 etc.) ---- */
.stdhead { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; flex-wrap: wrap; margin-top: 6px; }
.stdhead__tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.stdtab { display: inline-block; padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; font-size: 13px; font-weight: 500; color: var(--ink); background: var(--bg, #fff); text-decoration: none; }
.stdtab:hover { border-color: var(--brand); color: var(--brand); }
.stdtab.is-active { background: var(--brand); border-color: var(--brand); color: #fff; }
.stdtab .n { opacity: .7; font-weight: 400; }

.matrixwrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.matrix { border-collapse: collapse; width: max-content; min-width: 100%; font-size: 12.5px; }
table.matrix th, table.matrix td { border: 1px solid var(--line); padding: 0; }
table.matrix thead th { position: sticky; top: 0; background: #f6f7f9; font-size: 11.5px; padding: 7px 10px; white-space: nowrap; z-index: 2; }
table.matrix .matrix__corner, table.matrix .matrix__rowhead { position: sticky; left: 0; background: #f6f7f9; font-weight: 700; padding: 7px 12px; white-space: nowrap; z-index: 1; }
table.matrix .matrix__corner { z-index: 3; }
table.matrix td { min-width: 74px; text-align: center; }
table.matrix td.is-empty { background: repeating-linear-gradient(45deg, transparent 0 6px, rgba(0,0,0,.025) 6px 12px); }
.matrix__cell { display: block; padding: 8px 6px; font-variant-numeric: tabular-nums; color: var(--ink); text-decoration: none; font-weight: 600; }
.matrix__cell small { display: block; font-weight: 400; color: var(--muted); font-size: 10.5px; }
.matrix__cell:hover { background: color-mix(in srgb, var(--brand) 9%, white); color: var(--brand); }

/* ---- quote-sheet table view + lists ---- */
table.qlist { border-collapse: collapse; width: 100%; font-size: 13px; background: #fff; }
table.qlist th, table.qlist td { border-bottom: 1px solid var(--line); padding: 9px 10px; text-align: left; vertical-align: middle; }
table.qlist thead th { background: #f6f7f9; font-size: 11.5px; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); }
table.qlist td a { text-decoration: none; }
table.qlist tbody tr:hover { background: #fafbfc; }

/* ---- view toggle ---- */
.viewtoggle { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; }
.viewtoggle a { padding: 6px 14px; font-size: 12.5px; font-weight: 600; color: var(--muted); text-decoration: none; }
.viewtoggle a.is-active { background: var(--brand); color: #fff; }

/* ---- spec assets on PDP ---- */
.specassets { display: flex; gap: 18px; flex-wrap: wrap; align-items: flex-start; margin-top: 14px; }
.specassets__item { margin: 0; max-width: 560px; }
.specassets__item img { background: #fff; border: 1px solid var(--line); border-radius: 8px; width: 100%; height: auto; }
.specassets__item figcaption { font-size: 12px; color: var(--muted); margin-top: 6px; }
.specassets__drawing { max-width: 720px; }

/* ---- "By standard" dropdown in the header strip ---- */
.catnav ul.catnav__list li.menu-item-has-children { position: relative; }
.catnav ul.catnav__list li.menu-item-has-children > .sub-menu { display: none; position: absolute; top: 100%; left: 0; min-width: 240px; background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 14px 34px rgba(15,23,42,.12); padding: 6px; margin: 0; list-style: none; z-index: 60; max-height: 70vh; overflow-y: auto; }
.catnav ul.catnav__list li.menu-item-has-children:hover > .sub-menu,
.catnav ul.catnav__list li.menu-item-has-children:focus-within > .sub-menu { display: block; }
.catnav ul.catnav__list li.menu-item-has-children .sub-menu a { display: flex; justify-content: space-between; gap: 14px; padding: 8px 10px; border-radius: 7px; font-size: 13px; font-weight: 500; color: var(--ink); }
.catnav ul.catnav__list li.menu-item-has-children .sub-menu a:hover { background: color-mix(in srgb, var(--brand) 8%, white); color: var(--brand); }
.catnav ul.catnav__list li.menu-item-has-children .sub-menu .n { color: var(--muted); font-weight: 400; }

/* ================= vertical category menu (reference-mall style) ================= */

/* dropdown attached to the header "All categories" button */
.catnav__allwrap { position: relative; flex: none; }
.catnav__allwrap .catnav__all {
  appearance: none; border: 0; cursor: pointer; width: 100%;
  display: flex; align-items: center; gap: 8px; padding: 13px 16px; background: var(--brand); color: #fff;
  font-size: 14px; font-weight: 600; border-radius: 0; white-space: nowrap;
}
.catnav__allwrap .catnav__all:hover, .catnav__allwrap.is-open .catnav__all { background: var(--brand-dark); color: #fff; }
.megapanel { display: none; position: absolute; top: 100%; left: 0; z-index: 90; }
.catnav__allwrap:hover .megapanel, .catnav__allwrap.is-open .megapanel { display: block; }

/* vertical menu itself */
.cnav { background: #fff; border: 1px solid var(--line); border-radius: 0 0 var(--radius) var(--radius); box-shadow: var(--shadow); }
.cnav__list { list-style: none; margin: 0; padding: 6px 0; }
.cnav__item { position: relative; }
.cnav__row {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 9px 12px 9px 16px; font-size: 13.5px; font-weight: 600; color: var(--ink); text-decoration: none;
}
.cnav__row:hover { background: #f2f7fb; color: var(--brand); }
.cnav__meta { display: flex; align-items: center; gap: 8px; flex: none; }
.cnav__n { font-size: 11.5px; color: var(--muted); font-variant-numeric: tabular-nums; font-weight: 400; }
.cnav__arr { color: #b9c4cf; font-size: 15px; line-height: 1; transition: transform .12s; }
.cnav__item:hover .cnav__arr { transform: translateX(2px); color: var(--brand); }

/* fly-out with the sub categories */
.cnav__fly {
  display: none; position: absolute; top: -6px; left: 100%; z-index: 95;
  padding-left: 4px;
}
.cnav__item:hover .cnav__fly { display: block; }
.cnav__flyin {
  width: 560px; max-width: 72vw; background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 18px 44px rgba(15, 32, 48, .16); padding: 16px 18px 18px;
}
.cnav__flyhead {
  display: flex; align-items: baseline; gap: 10px; font-size: 14.5px; font-weight: 700; color: var(--ink);
  padding-bottom: 10px; margin-bottom: 12px; border-bottom: 1px solid var(--line); text-decoration: none;
}
.cnav__flyhead span { font-size: 12px; font-weight: 500; color: var(--muted); }
.cnav__flyhead:hover { color: var(--brand); }
.cnav__flygrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px 14px; }
.cnav__sub {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 7px 8px; border-radius: var(--radius-sm); font-size: 13px; color: var(--ink); text-decoration: none;
}
.cnav__sub:hover { background: var(--bg-alt); color: var(--brand); }
.cnav__subn { font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; flex: none; }

/* header panel keeps the menu compact (no overflow clipping: the fly-out
   lives outside the box, so anything that scrolls would cut it off) */
.megapanel .cnav { width: 264px; border-radius: 0 0 var(--radius) var(--radius); border-top: 0; }

/* ---------- homepage top: sidebar + static banner (no carousel) ---------- */
.homehero { background: linear-gradient(180deg, #f7fafc 0%, #eef4f9 100%); border-bottom: 1px solid var(--line); }
.homehero__grid { display: grid; grid-template-columns: 1fr; gap: 20px; padding: 22px 20px 30px; align-items: start; }
.homehero__sidehead {
  display: flex; align-items: center; gap: 8px; background: var(--brand); color: #fff;
  font-size: 14px; font-weight: 700; padding: 12px 16px; border-radius: var(--radius) var(--radius) 0 0;
}
.homehero__sidehead::before { content: "☰"; font-size: 14px; }
.homehero__side .cnav { border-radius: 0 0 var(--radius) var(--radius); border-top: 0; }
.homehero__banner { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 34px 36px; box-shadow: var(--shadow); }
.homehero__banner h1 { font-size: 34px; margin-bottom: 12px; }
.homehero__banner p.lead { font-size: 16.5px; color: var(--ink-soft); max-width: 56ch; margin-bottom: 22px; }
.homehero__banner .hero__cta { margin-bottom: 0; }
.homehero__tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 16px; }
.htile {
  display: flex; flex-direction: column; gap: 3px; background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px 20px; text-decoration: none; transition: .15s;
}
.htile:hover { border-color: var(--brand); box-shadow: var(--shadow-sm); transform: translateY(-1px); }
.htile__big { font-size: 26px; font-weight: 800; color: var(--brand); line-height: 1.1; }
.htile__big small { font-size: 13px; font-weight: 600; color: var(--ink-soft); margin-left: 3px; }
.htile__t { font-size: 14px; font-weight: 700; color: var(--ink); }
.htile__d { font-size: 12.5px; color: var(--muted); }

@media (min-width: 1100px) {
  .homehero__grid { grid-template-columns: 264px 1fr; gap: 22px; padding: 26px 20px 36px; }
  .homehero__sidehead { border-radius: var(--radius) var(--radius) 0 0; }
}
@media (max-width: 1099px) {
  .homehero__side { order: 2; }
  .cnav__fly { display: none !important; }
  .homehero__sidehead { border-radius: var(--radius) var(--radius) 0 0; }
  .homehero__banner { padding: 26px 22px; }
  .homehero__banner h1 { font-size: 27px; }
  .homehero__tiles { grid-template-columns: 1fr; }
}

/* ================= facet pills (reference-mall filter rows) ================= */
.listing--full { display: block; }
.pillsbox {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 6px 16px; margin-bottom: 18px;
}
.prow { display: flex; align-items: flex-start; gap: 14px; padding: 9px 0; border-bottom: 1px dashed var(--line); }
.prow:last-child { border-bottom: 0; }
.prow__label { flex: none; width: 96px; padding-top: 5px; font-size: 13px; font-weight: 700; color: var(--ink); }
.prow__pills { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.fpill {
  display: inline-flex; align-items: center; gap: 4px; padding: 4px 12px; border-radius: 3px;
  border: 1px solid var(--line); background: #fff; font-size: 12.5px; font-weight: 500;
  color: var(--ink); text-decoration: none; line-height: 1.5; white-space: nowrap; transition: .12s;
}
.fpill:hover { border-color: var(--brand); color: var(--brand); }
.fpill.is-active { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 600; }
.fpill--more { cursor: pointer; font-family: inherit; }
.fpill--more:hover { background: var(--bg-alt); }
.prow__extra { display: contents; }
.prow__extra[hidden] { display: none; }

@media (max-width: 760px) {
  .prow { flex-direction: column; gap: 7px; padding: 10px 0; }
  .prow__label { width: auto; padding-top: 0; }
}

/* ================= top-level category panel (reference-mall) ================= */
.toppanel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 6px 16px; }
.toppanel .prow__label { width: 150px; }
.prow__label--link { color: var(--ink); text-decoration: none; }
.prow__label--link:hover { color: var(--brand); }
.pillsbox--top { background: var(--bg-alt); border-color: transparent; padding: 10px 16px; }

/* ---------- footer structural browse links ---------- */

/* ================= header specification strip =================
 * "Browse by spec": material / size / grade / finish / standard. Sits on its
 * own row under the category bar so the mega-panel's positioning is untouched
 * and nothing gets clipped by the horizontal scroll used on small screens.
 */
.hdrnav { border-top: 1px solid var(--line); background: var(--bg-alt); }
.hdrnav__inner { display: flex; align-items: center; min-height: 42px; }

.inav { display: flex; align-items: center; flex-wrap: wrap; gap: 0 2px; }
.inav__lead {
  font-size: 11px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase;
  color: var(--muted); margin-right: 12px; white-space: nowrap;
}
.inav__grp { position: relative; }
.inav__head {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 11px; border-radius: var(--radius-sm);
  font-size: 13.5px; font-weight: 600; color: var(--ink-soft);
  text-decoration: none; white-space: nowrap;
}
.inav__head:hover,
.inav__grp:focus-within .inav__head { background: var(--brand-tint); color: var(--brand); }
.inav__arr { font-size: 9px; line-height: 1; color: var(--muted-2); }
.inav__grp:hover .inav__arr,
.inav__grp:focus-within .inav__arr { color: var(--brand); }

.inav__fly {
  display: none; position: absolute; left: 0; top: calc(100% + 1px); z-index: 70;
  min-width: 216px; max-height: 62vh; overflow-y: auto;
  padding: 8px; background: var(--bg); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-lg);
}
.inav__grp:hover .inav__fly,
.inav__grp:focus-within .inav__fly { display: grid; gap: 1px; }
.inav__fly a {
  display: block; padding: 7px 10px; border-radius: var(--radius-sm);
  font-size: 13px; font-weight: 500; color: var(--ink);
  text-decoration: none; white-space: nowrap;
}
.inav__fly a:hover { background: var(--brand-tint); color: var(--brand); }

.inav__plain {
  padding: 8px 11px; border-radius: var(--radius-sm);
  font-size: 13.5px; font-weight: 600; color: var(--brand);
  text-decoration: none; white-space: nowrap;
}
.inav__plain:hover { background: var(--brand-tint); }

@media (max-width: 900px) {
  /* The strip scrolls sideways; the fly-outs would be clipped inside that
     scroll container, so on small screens the group headings carry the links. */
  .hdrnav__inner { overflow-x: auto; scrollbar-width: none; }
  .hdrnav__inner::-webkit-scrollbar { display: none; }
  .inav__fly { display: none !important; }
  .inav__lead { display: none; }
}

/* ---- product page: browse this specification ---- */
.pdp__specnav .landing__links .fpill { font-size: 13px; }
