/* ==================================================================
   BESPOKE DOORS - HARDWARE SECTION
   Extends assets/css/site.css. Tokens and type come from there.
   ================================================================== */

/* ---------- breadcrumbs ---------- */
.hw-crumbs { padding: var(--s-4) 0 0; font-family: var(--f-body); font-size: 12px;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--c-mute); }
.hw-crumbs a { color: var(--c-mute); text-decoration: none; }
.hw-crumbs a:hover { color: var(--c-terracotta); }
.hw-crumbs span { margin: 0 var(--s-2); }
.hw-crumbs span[aria-current] { color: var(--c-ink); margin-left: 0; }

/* ---------- landing hero ---------- */
.hw-hero { position: relative; display: grid; grid-template-columns: 1.05fr 1fr;
  align-items: stretch; background: var(--c-ink); color: var(--c-bone); }
.hw-hero-img { position: relative; min-height: 62vh; overflow: hidden; }
.hw-hero-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hw-hero-copy { padding: var(--s-24) var(--s-16); display: flex; flex-direction: column;
  justify-content: center; max-width: 720px; }
.hw-hero-copy h1 { color: var(--c-bone); margin: var(--s-4) 0 var(--s-5); }
.hw-hero-copy h1 em { color: var(--c-sand); font-style: italic; }
.hw-hero-copy .lede { color: var(--c-bone-mute); }
.hw-hero-copy .btn-row { margin-top: var(--s-8); }

/* ---------- category page header ---------- */
.hw-head { padding: var(--s-16) 0 var(--s-12); }
.hw-head-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: var(--s-16); align-items: center; }
.hw-head-grid .lede { margin: var(--s-5) 0 0; }
.hw-head-grid .btn-row { margin-top: var(--s-8); }
.hw-head-fig { margin: 0; aspect-ratio: 4 / 5; overflow: hidden; background: var(--c-cream); }
.hw-head-fig img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------- filters ---------- */
.hw-filter { z-index: 30; }
.hw-finfilter { position: sticky; top: 0; z-index: 29; background: var(--c-cream);
  border-bottom: 1px solid var(--c-rule); padding: var(--s-3) 0; }
.hw-finfilter .shell { display: flex; align-items: center; gap: var(--s-2);
  flex-wrap: wrap; overflow-x: auto; }
.hw-finfilter-label { font-family: var(--f-body); font-size: 11px; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--c-mute); margin-right: var(--s-2); }
.hw-finchip { display: inline-flex; align-items: center; gap: var(--s-2);
  font-family: var(--f-body); font-size: 12px; letter-spacing: 0.04em; color: var(--c-mute);
  background: none; border: 1px solid transparent; border-radius: 999px;
  padding: 5px 12px 5px 6px; cursor: pointer; white-space: nowrap; transition: all var(--t-fast); }
.hw-finchip:hover { color: var(--c-ink); border-color: var(--c-rule); }
.hw-finchip.active { color: var(--c-ink); border-color: var(--c-ink); background: rgba(255,255,255,0.5); }
.hw-finchip[data-fin="all"] { padding-left: 12px; }

/* ---------- swatches ---------- */
.hw-sw { display: inline-block; width: 16px; height: 16px; border-radius: 50%;
  border: 1px solid rgba(42,32,24,0.22); position: relative; flex: none; }
.hw-sw-lg { width: 34px; height: 34px; }
.hw-sw i { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.hw-fins { display: flex; gap: 6px; flex-wrap: wrap; margin: var(--s-4) 0 var(--s-4); }

/* ---------- product grid ---------- */
.hw-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-12) var(--s-8); }
.hw-card { display: flex; flex-direction: column; border-top: 1px solid var(--c-rule);
  padding-top: var(--s-6); }
.hw-card[hidden] { display: none; }
.hw-media { position: relative; aspect-ratio: 1 / 1; background: var(--c-cream);
  display: flex; align-items: center; justify-content: center; overflow: hidden; }
.hw-media img { width: 100%; height: 100%; object-fit: contain; padding: 12%;
  display: block; transition: transform var(--t-slow); }
.hw-card:hover .hw-media img { transform: scale(1.04); }
.hw-ph { font-family: var(--f-display); font-size: 62px; font-weight: 600;
  color: rgba(42,32,24,0.14); letter-spacing: 0.04em; }
.hw-badge { position: absolute; top: var(--s-3); left: var(--s-3); z-index: 2;
  background: var(--c-terracotta); color: var(--c-bone); font-family: var(--f-body);
  font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; padding: 5px 9px; }
.hw-thumbs { display: flex; gap: 6px; margin-top: 6px; }
.hw-thumb { width: 44px; height: 44px; background: var(--c-cream); border: 1px solid transparent;
  padding: 3px; cursor: pointer; transition: border-color var(--t-fast); }
.hw-thumb img { width: 100%; height: 100%; object-fit: contain; }
.hw-thumb.is-on, .hw-thumb:hover { border-color: var(--c-ink); }
.hw-body { padding-top: var(--s-5); display: flex; flex-direction: column; flex: 1; }
.hw-meta { display: flex; align-items: baseline; gap: var(--s-3); font-family: var(--f-body);
  font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--c-mute); margin: 0; }
.hw-brand { color: var(--c-terracotta); }
.hw-name { font-family: var(--f-display); font-size: 26px; font-weight: 600; line-height: 1.1;
  margin: var(--s-2) 0 var(--s-3); color: var(--c-ink); }
.hw-blurb { font-family: var(--f-body); font-size: 15px; line-height: 1.62; color: var(--c-mute);
  margin: 0; }
.hw-specs { border-top: 1px solid var(--c-rule); margin-top: auto; }
.hw-specs summary { list-style: none; cursor: pointer; padding: var(--s-3) 0;
  font-family: var(--f-body); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--c-ink); display: flex; justify-content: space-between; align-items: center; }
.hw-specs summary::-webkit-details-marker { display: none; }
.hw-specs summary::after { content: "+"; font-size: 15px; color: var(--c-mute); }
.hw-specs[open] summary::after { content: "\2212"; }
.hw-specs dl { margin: 0 0 var(--s-4); font-family: var(--f-body); font-size: 13.5px; }
.hw-specs dl > div { display: grid; grid-template-columns: 96px 1fr; gap: var(--s-4);
  padding: 5px 0; border-bottom: 1px solid rgba(42,32,24,0.07); }
.hw-specs dt { color: var(--c-mute-soft); }
.hw-specs dd { margin: 0; color: var(--c-ink); }
/* ---------- price ---------- */
.hw-price { display: flex; align-items: baseline; gap: 7px; margin: 0 0 var(--s-4);
  font-family: var(--f-body); }
.hw-from { font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--c-mute-soft); }
.hw-price strong { font-family: var(--f-display); font-size: 23px; font-weight: 600;
  color: var(--c-ink); letter-spacing: -0.01em; }
.hw-gst { font-size: 11px; letter-spacing: 0.08em; color: var(--c-mute-soft); }
.hw-price-poa { font-size: 13px; color: var(--c-mute); font-style: italic; }
.hw-ptable { width: 100%; border-collapse: collapse; margin: 0 0 var(--s-4);
  font-family: var(--f-body); font-size: 12.5px; }
.hw-ptable caption { caption-side: top; text-align: left; font-size: 10px;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--c-mute-soft);
  padding: var(--s-2) 0 var(--s-3); }
.hw-ptable td { padding: 5px 0; border-bottom: 1px solid rgba(42,32,24,0.07);
  color: var(--c-mute); vertical-align: top; }
.hw-ptable td:nth-child(2) { width: 30%; padding-left: var(--s-3); color: var(--c-mute-soft); }
.hw-ptable .hw-p { width: 68px; text-align: right; color: var(--c-ink);
  font-variant-numeric: tabular-nums; white-space: nowrap; }
.hw-ptable-more { font-size: 12px; line-height: 1.55; color: var(--c-mute-soft);
  margin: 0 0 var(--s-4); }

.hw-add { font-family: var(--f-body); font-size: 11px; letter-spacing: 0.14em;
  text-transform: uppercase; background: none; border: 1px solid var(--c-ink); color: var(--c-ink);
  padding: 11px var(--s-5); cursor: pointer; transition: all var(--t-fast); align-self: flex-start; }
.hw-add:hover { background: var(--c-ink); color: var(--c-bone); }
.hw-add.is-on { background: var(--c-terracotta); border-color: var(--c-terracotta); color: var(--c-bone); }

.hw-empty { text-align: center; font-family: var(--f-body); color: var(--c-mute);
  padding: var(--s-16) 0; }

/* ---------- note + disclaimer ---------- */
.hw-note { margin-top: var(--s-20); padding: var(--s-10); background: var(--c-cream);
  max-width: var(--shell-narrow); }
.hw-note-t { font-family: var(--f-display); font-size: 22px; font-weight: 600;
  margin: 0 0 var(--s-3); color: var(--c-ink); }
.hw-note p { font-family: var(--f-body); font-size: 15px; line-height: 1.68;
  color: var(--c-mute); margin: 0; }
.hw-disclaimer { margin-top: var(--s-10); font-family: var(--f-body); font-size: 12.5px;
  line-height: 1.65; color: var(--c-mute-soft); max-width: var(--shell-narrow); }

/* ---------- landing: why ---------- */
.hw-why { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--s-10); }
.hw-why-n { font-family: var(--f-display); font-size: 13px; letter-spacing: 0.1em;
  color: var(--c-terracotta); }
.hw-why h3 { font-family: var(--f-display); font-size: 21px; font-weight: 600; line-height: 1.2;
  margin: var(--s-3) 0 var(--s-3); color: var(--c-ink); }
.hw-why p { font-family: var(--f-body); font-size: 14.5px; line-height: 1.65;
  color: var(--c-mute); margin: 0; }

/* ---------- landing: standard ---------- */
.hw-std { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: var(--s-16); align-items: center; }
.hw-std .btn-row { margin-top: var(--s-6); }
.hw-std-fig { margin: 0; aspect-ratio: 3 / 4; overflow: hidden; }
.hw-std-fig img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------- landing: tiles ---------- */
.hw-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-8);
  margin-top: var(--s-16); }
.hw-tile { text-decoration: none; color: inherit; display: block; }
.hw-tile-img { aspect-ratio: 4 / 3; overflow: hidden; background: var(--c-cream); }
.hw-tile-img img { width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform var(--t-slow); }
.hw-tile:hover .hw-tile-img img { transform: scale(1.05); }
.hw-tile-body { padding: var(--s-5) 0 0; }
.hw-tile-body h3 { font-family: var(--f-display); font-size: 24px; font-weight: 600;
  margin: 0 0 var(--s-2); color: var(--c-ink); }
.hw-tile-body p { font-family: var(--f-body); font-size: 14.5px; line-height: 1.6;
  color: var(--c-mute); margin: 0 0 var(--s-3); }
.hw-tile-go { font-family: var(--f-body); font-size: 11px; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--c-terracotta); }

/* ---------- landing: pivot band ---------- */
.hw-pivot { max-width: var(--shell-narrow); }
.hw-pivot .btn-row { margin-top: var(--s-6); }

/* ---------- landing: finish row ---------- */
.hw-finrow { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--s-6);
  margin-top: var(--s-10); }
.hw-finlink { display: flex; flex-direction: column; align-items: center; gap: var(--s-2);
  text-decoration: none; font-family: var(--f-body); font-size: 12px; letter-spacing: 0.05em;
  color: var(--c-mute); width: 96px; transition: color var(--t-fast); }
.hw-finlink:hover { color: var(--c-ink); }

/* ---------- landing: brands ---------- */
.hw-brands { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-12); }
.hw-brandcard h3 { margin: var(--s-3) 0 var(--s-4); }
.hw-brandlist { list-style: none; padding: 0; margin: var(--s-5) 0 0;
  border-top: 1px solid var(--c-rule); }
.hw-brandlist li { font-family: var(--f-body); font-size: 14px; color: var(--c-mute);
  padding: var(--s-3) 0; border-bottom: 1px solid var(--c-rule); }

/* ---------- shortlist bar ---------- */
.hw-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; background: var(--c-ink);
  color: var(--c-bone); box-shadow: 0 -8px 30px rgba(0,0,0,0.16); }
.hw-bar-in { display: flex; align-items: center; justify-content: space-between;
  gap: var(--s-6); padding: var(--s-4) 0; }
.hw-bar-toggle { background: none; border: 0; color: var(--c-bone); cursor: pointer;
  font-family: var(--f-body); font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase;
  display: flex; align-items: center; gap: var(--s-3); }
.hw-count { display: inline-flex; align-items: center; justify-content: center;
  min-width: 26px; height: 26px; border-radius: 50%; background: var(--c-terracotta);
  font-size: 12px; letter-spacing: 0; }
.hw-bar-cta { flex: none; }
.hw-panel { border-top: 1px solid rgba(242,235,221,0.18); padding: var(--s-6) 0;
  max-height: 46vh; overflow-y: auto; }
.hw-panel ul { list-style: none; padding: 0; margin: 0 0 var(--s-5); }
.hw-panel li { display: flex; justify-content: space-between; align-items: center;
  gap: var(--s-4); padding: var(--s-3) 0; border-bottom: 1px solid rgba(242,235,221,0.14);
  font-family: var(--f-body); font-size: 14px; }
.hw-panel li button { background: none; border: 0; color: var(--c-bone-mute); cursor: pointer;
  font-family: var(--f-body); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; }
.hw-panel li button:hover { color: var(--c-ember); }
.hw-panel-note { font-family: var(--f-body); font-size: 13px; line-height: 1.6;
  color: var(--c-bone-mute); margin: 0 0 var(--s-4); max-width: 60ch; }
.hw-clear { background: none; border: 1px solid rgba(242,235,221,0.35); color: var(--c-bone-mute);
  font-family: var(--f-body); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase;
  padding: 9px var(--s-5); cursor: pointer; }
.hw-clear:hover { color: var(--c-bone); border-color: var(--c-bone); }
body.hw-has-list { padding-bottom: 84px; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .hw-grid { grid-template-columns: repeat(2, 1fr); }
  .hw-tiles { grid-template-columns: repeat(2, 1fr); }
  .hw-why { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .hw-crumbs { padding-top: var(--s-8); }
  .hw-hero { grid-template-columns: 1fr; }
  .hw-hero-img { min-height: 0; height: 44vh; }
  .hw-hero-copy { padding: var(--s-16) var(--s-6); }
  .hw-head-grid, .hw-std, .hw-brands { grid-template-columns: 1fr; gap: var(--s-10); }
  .hw-head-fig { aspect-ratio: 16 / 10; order: -1; }
  .hw-std-fig { aspect-ratio: 16 / 10; }
}
@media (max-width: 620px) {
  .hw-grid { grid-template-columns: 1fr; gap: var(--s-10); }
  .hw-tiles { grid-template-columns: 1fr; }
  .hw-why { grid-template-columns: 1fr; gap: var(--s-8); }
  .hw-bar-in { flex-direction: column; align-items: stretch; gap: var(--s-3); }
  .hw-bar-cta { text-align: center; }
  body.hw-has-list { padding-bottom: 140px; }
  .hw-finrow { gap: var(--s-4); }
  .hw-finlink { width: 74px; font-size: 11px; }
}
