:root {
  --paper: #f1ede4;
  --ink: #121212;
  --muted: #6b675f;
  --line: #dcd6c9;
  --card: #ffffff;
  --accent: #c8f135;
  --display: "Bricolage Grotesque", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
[hidden] { display: none !important; }

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

body {
  min-height: 100dvh;
  background:
    radial-gradient(circle at 1px 1px, rgba(18, 18, 18, 0.08) 1px, transparent 0) 0 0 / 22px 22px,
    var(--paper);
  color: var(--ink);
  font: 500 15px/1.45 "Manrope", sans-serif;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
}

.blob {
  position: fixed;
  width: 360px;
  height: 360px;
  right: -180px;
  top: -170px;
  border-radius: 50%;
  background: var(--accent);
  filter: blur(80px);
  opacity: 0.5;
  pointer-events: none;
}

.wrap {
  position: relative;
  max-width: 560px;
  margin: 0 auto;
  padding: 0 16px max(28px, env(safe-area-inset-bottom));
}

a { color: inherit; }

mark {
  background: var(--accent);
  color: var(--ink);
  padding: 0 5px;
  border-radius: 5px;
}

/* ---- header (compact: products must be visible on the first screen) ---- */
.head { padding-top: max(18px, env(safe-area-inset-top)); }
.wordmark {
  font: 800 clamp(38px, 11.5vw, 54px)/0.9 var(--display);
  letter-spacing: -0.045em;
  white-space: nowrap;
}
.bolt { height: 0.74em; width: auto; vertical-align: -0.01em; margin: 0 0.035em 0 0.045em; }
.tagline { margin-top: 8px; font-size: 14px; font-weight: 700; }

.demo {
  margin-top: 10px;
  padding: 5px 10px;
  border: 1.5px dashed var(--ink);
  border-radius: 8px;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ---- sticky search + categories ---- */
.bar {
  position: sticky;
  top: 0;
  z-index: 5;
  margin: 14px -16px 0;
  padding: 10px 16px;
  background: rgba(241, 237, 228, 0.88);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}
.finder-box {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 52px;
  padding: 0 5px 0 14px;
  border-radius: 16px;
  background: var(--ink);
  color: var(--paper);
  box-shadow: 0 10px 24px rgba(18, 18, 18, 0.16);
}
.finder-box:focus-within { box-shadow: 0 0 0 3px var(--accent), 0 10px 24px rgba(18, 18, 18, 0.16); }
.hash { font: 800 26px/1 var(--display); color: var(--accent); }
#q {
  flex: 1;
  min-width: 0;
  height: 100%;
  border: 0;
  background: none;
  outline: none;
  font: 800 20px var(--display); /* >= 16px so iOS does not zoom on focus */
  letter-spacing: -0.02em;
  color: var(--paper);
  -webkit-appearance: none;
  appearance: none;
}
#q::placeholder { color: #8f8a80; font: 600 16px "Manrope", sans-serif; letter-spacing: 0; }
#q::-webkit-search-cancel-button { display: none; }
.clear {
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: var(--paper);
  color: var(--ink);
  font-size: 22px;
  cursor: pointer;
}

.chips {
  display: flex;
  gap: 6px;
  margin: 10px -16px 0;
  padding: 0 16px;
  overflow-x: auto;
  scrollbar-width: none;
  scroll-padding-inline: 16px;
  scroll-snap-type: x proximity;
}
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none;
  scroll-snap-align: start;
  height: 36px;
  padding: 0 14px;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink);
  font: 700 13px "Manrope", sans-serif;
  cursor: pointer;
}
.chip[aria-pressed="true"] { background: var(--ink); color: var(--accent); }

/* ---- section label ---- */
.label {
  display: flex;
  align-items: center;
  margin: 10px 0;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  white-space: nowrap;
}
.label i { flex: 1; height: 1.5px; margin-left: 10px; background: var(--ink); }

/* ---- product cards: compact row, the whole card is the link ---- */
.list { list-style: none; display: grid; gap: 10px; }

.card a {
  position: relative;
  display: grid;
  grid-template-columns: 84px 1fr 32px;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 18px;
  background: var(--card);
  text-decoration: none;
  box-shadow: 0 6px 18px rgba(18, 18, 18, 0.06);
  transition: transform 0.12s ease;
}
.card a:active { transform: scale(0.98); }

.shot {
  position: relative;
  aspect-ratio: 1;
  border-radius: 12px;
  background: var(--paper);
  display: grid;
  place-items: center;
}
/* absolute so a large photo can never grow the box and spill over the text */
.shot img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; border-radius: 12px; mix-blend-mode: multiply; }
.code { z-index: 1; }
.ph { width: 30%; color: var(--line); }
.code {
  position: absolute;
  left: -5px;
  top: -5px;
  min-width: 36px;
  height: 36px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--accent);
  display: grid;
  place-items: center;
  font: 800 15px/1 var(--display);
  letter-spacing: -0.03em;
  transform: rotate(-8deg);
  box-shadow: 0 4px 10px rgba(18, 18, 18, 0.2);
}

.info { min-width: 0; }
.name {
  font: 800 16px/1.15 var(--display);
  letter-spacing: -0.02em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.meta { margin-top: 2px; font-size: 11.5px; font-weight: 700; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.prices { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 6px; margin-top: 5px; }
.price { font: 800 17px/1 var(--display); letter-spacing: -0.03em; }
.prices s { font-size: 11.5px; font-weight: 700; color: var(--muted); }
.prices em {
  font-style: normal;
  font-size: 11px;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 999px;
  background: var(--accent);
}
/* one line only: chips that don't fit wrap out of view instead of being cut in half */
.specs { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; max-height: 21px; overflow: hidden; }
.specs span {
  flex: none;
  padding: 1px 7px;
  border: 1.2px solid var(--ink);
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 700;
}
.checked { margin-top: 4px; font-size: 10.5px; font-weight: 600; color: var(--muted); }

.arrow {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--accent);
  display: grid;
  place-items: center;
  font-weight: 800;
}

/* exact number search: the found product gets the spotlight + a full button */
.card.hit a { grid-template-columns: 1fr; gap: 12px; padding: 14px; box-shadow: 0 0 0 2.5px var(--ink), 0 16px 36px rgba(18, 18, 18, 0.14); }
.card.hit .shot { aspect-ratio: 4 / 3; max-height: 42vh; width: 100%; }
.card.hit .code { min-width: 64px; height: 64px; font-size: 27px; left: -6px; top: -6px; }
.card.hit .name { font-size: 23px; -webkit-line-clamp: 3; }
.card.hit .meta { font-size: 12.5px; }
.card.hit .price { font-size: 27px; }
.card.hit .prices s { font-size: 14px; }
.card.hit .specs { max-height: none; }
.card.hit .specs span { font-size: 12px; padding: 2px 9px; }
.go {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 54px;
  padding: 0 18px;
  border-radius: 14px;
  background: var(--accent);
  color: var(--ink);
  font-size: 17px;
  font-weight: 800;
}
.go b { font-size: 20px; }

.empty {
  padding: 20px 16px;
  border: 2px dashed var(--line);
  border-radius: 16px;
  font-weight: 600;
  color: var(--muted);
  text-align: center;
}
.empty b { color: var(--ink); }

/* ---- footer ---- */
.foot { margin-top: 28px; display: grid; gap: 14px; }
.tg {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 56px;
  padding: 0 18px;
  border-radius: 16px;
  background: var(--accent);
  text-decoration: none;
  font: 800 16px var(--display);
  letter-spacing: -0.02em;
}
.tg b { font-size: 20px; }
.socials { display: flex; flex-wrap: wrap; gap: 6px; }
.socials a {
  display: inline-flex;
  align-items: center;
  height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  background: rgba(18, 18, 18, 0.06);
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
}
.disc { font-size: 11.5px; line-height: 1.55; color: var(--muted); }
.disc b { color: var(--ink); }

@media (hover: hover) {
  .card a:hover { box-shadow: 0 12px 28px rgba(18, 18, 18, 0.12); }
}

@media (min-width: 720px) {
  .head { padding-top: 48px; }
  .card a { grid-template-columns: 112px 1fr 36px; }
}

@media (prefers-reduced-motion: reduce) {
  .card a { transition: none; }
}
