@font-face {
  font-family: Jost;
  src: url('/fonts/Jost-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: Jost;
  src: url('/fonts/Jost-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: Jost;
  src: url('/fonts/Jost-Italic.ttf') format('truetype');
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
:root {
  font-family: Jost, system-ui, sans-serif;
  color: var(--ink);
  background: #f9f5f0;
  --accent: #551b07;
  --ink: var(--accent);
  --border: #dfcfc3;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; }
.wrap { width: min(1180px, calc(100% - 2rem)); margin-inline: auto; }
.top { position: sticky; top: 0; z-index: 1; background: var(--accent); color: #fff8ef; }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 74px; }
.brand { display: block; max-width: 45%; height: auto; }
.top .outline { color: inherit; border-color: #a8897c; }
#cart-count { margin-left: .4rem; }
#header-total { display: block; white-space: nowrap; }
.intro { padding: clamp(1rem, 3vw, 2rem) 0 1.5rem; border-bottom: 1px solid var(--border); margin-bottom: 1.5rem; }
h1, #cart-title { font-size: clamp(2rem, 5vw, 3.7rem); font-weight: 700; line-height: 1.1; margin: 0; }
.intro h1 { font-size: clamp(1.75rem, 3.8vw, 2.8rem); }
.intro p { margin: .8rem 0 0; }
.toolbar { display: grid; grid-template-columns: minmax(0, 29rem) auto; gap: .5rem 1rem; align-items: end; }
.toolbar label { display: grid; gap: .5rem; font-weight: 600; }
.catalog-controls { display: flex; flex-wrap: wrap; gap: .5rem 1rem; }
input, select, button { font: inherit; min-height: 44px; border-radius: .45rem; }
input, select { width: 100%; border: 1px solid var(--border); padding: .6rem .85rem; background: white; color: var(--ink); }
#results { margin: 1rem 0; }
button { cursor: pointer; border: 1px solid transparent; padding: .55rem .85rem; background: var(--accent); color: white; font-weight: 600; }
button:hover:not(:disabled) { filter: brightness(1.15); }
button:disabled { opacity: .55; cursor: default; }
:focus-visible { outline: 3px solid #b26838; outline-offset: 3px; }
.outline { background: transparent; color: var(--ink); border-color: var(--border); }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr)); gap: 1rem; padding-bottom: 3rem; }
.card { background: #fffdfa; border: 1px solid var(--border); border-radius: .75rem; overflow: hidden; display: flex; flex-direction: column; }
.photo { position: relative; aspect-ratio: 4 / 3; display: grid; place-items: center; background: #ede1d6; }
.photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.photo img.loading { opacity: 0; }
.placeholder, .meta, .code { color: #654b41; font-size: .9rem; }
.card-info { padding: 1rem; display: flex; flex-direction: column; flex: 1; }
.card-info h2 { font-size: 1rem; line-height: 1.35; margin: .3rem 0 1rem; }
.card-info a, #product-detail a { color: var(--accent); }
.purchase-controls { margin-top: auto; }
#product-detail { padding: 1.5rem 0 3rem; }
#product-detail h1 { font-size: clamp(1.4rem, 3vw, 2.25rem); margin: .7rem 0 1.25rem; }
.detail-layout { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 1.25rem; }
.product-gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; }
.product-gallery .photo { border-radius: .65rem; overflow: hidden; }
.product-gallery .photo:first-child { grid-column: 1 / -1; }
.product-specs { border: 1px solid var(--border); padding: 1rem; border-radius: .65rem; background: #fffdfa; align-self: start; }
.spec-list { display: grid; grid-template-columns: 1fr auto; gap: .4rem 1rem; margin-bottom: 0; }
.spec-list dd { margin: 0; text-align: right; }
.product-presentation { white-space: pre-line; max-width: 75ch; line-height: 1.65; }
.page-nav { display: flex; flex-wrap: wrap; gap: .45rem 1.25rem; padding: .8rem 0; border-bottom: 1px solid var(--border); }
.page-nav a, .editorial a { color: var(--accent); }
.page-nav [aria-current] { font-weight: 700; }
.editorial { max-width: 64rem; margin: 0 auto; padding: 1.5rem 0 5rem; }
.editorial h1 { font-size: clamp(1.75rem, 4vw, 2.8rem); margin-bottom: 1.25rem; }
.editorial-page { display: block; width: 100%; height: auto; margin-bottom: 1rem; border-radius: .6rem; }
.guide-pages { max-width: 54rem; margin: auto; }
.guide-final { max-width: 54rem; margin: auto; padding: clamp(1rem, 4vw, 3rem); background: #f3d9bc; border: .45rem solid var(--accent); border-radius: .6rem; }
.guide-final h2 { margin-top: 0; }
.guide-final ul { margin-bottom: 2.5rem; }
.guide-final address { font-style: normal; }
.catalog-sheet { position: relative; margin-bottom: 1rem; }
.catalog-sheet .editorial-page { margin: 0; border-radius: 0; }
.catalog-hotspot, .catalog-mask { position: absolute; }
.catalog-mask { background: #fde4c6; }
.catalog-hotspot:hover, .catalog-hotspot:focus-visible { outline: 2px solid var(--accent); outline-offset: 0; }
.floating-whatsapp { position: fixed; z-index: 2; right: max(1rem, env(safe-area-inset-right)); bottom: max(1rem, env(safe-area-inset-bottom)); display: grid; place-items: center; width: 3.5rem; height: 3.5rem; border-radius: 50%; color: white; background: #187b4d; box-shadow: 0 .2rem .7rem #0004; }
body { padding-bottom: 3.5rem; }
.code { margin: 0; }
.price { font-weight: 700; margin: auto 0 .35rem; }
.product-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .65rem; margin-top: .5rem; }
.product-actions output { min-width: 2ch; text-align: center; }
.meta { margin: 0 0 .85rem; }
dialog { border: 0; border-left: 1px solid var(--border); margin: 0 0 0 auto; width: min(100vw, 460px); max-width: 100%; height: 100%; max-height: 100%; padding: 1.25rem; background: #fffdfa; color: var(--ink); }
dialog::backdrop { background: #26140fad; }
.cart-header, .cart-total, .quantity { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
#cart-title { font-size: 2rem; }
#cart-items { list-style: none; padding: 0; margin: 1.5rem 0; }
.cart-row { border-bottom: 1px solid var(--border); padding: 1rem 0; }
.cart-row p { margin: .4rem 0 .65rem; }
.quantity { justify-content: flex-start; flex-wrap: wrap; }
.quantity button { min-width: 44px; }
.cart-total { margin-bottom: 1rem; }
#order-minimum { border-left: 3px solid var(--accent); background: #f9f5f0; padding: .65rem .8rem; }
#checkout { width: 100%; background: #255838; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
@media (max-width: 740px) {
  .toolbar, .detail-layout { grid-template-columns: 1fr; }
}
