/* ==========================================================================
   Tofikolo.pl – styl „ściana kafelków”
   Zasady: bez inline-style (CSP), bez zewnętrznych fontów, kontrast AA,
   widoczny focus, uszanowane prefers-reduced-motion.
   ========================================================================== */

/* ---------- fonty (własne, bez Google CDN) ---------- */
@font-face {
  font-family: "Shrikhand";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/shrikhand-latin-ext-400-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Shrikhand";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/shrikhand-latin-400-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Bricolage Grotesque";
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url("/fonts/bricolage-grotesque-latin-ext-wght-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Bricolage Grotesque";
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url("/fonts/bricolage-grotesque-latin-wght-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- tokeny ---------- */
:root {
  color-scheme: light;
  --ink: #0f3a4b;
  --ink-soft: #1f5368;
  --muted: #4a6672;
  --foam: #f3fafd;
  --white: #ffffff;
  --grout: #e2f0f7;
  --sky: #cbe7f7;
  --butter: #ffc933;
  --butter-soft: #ffe9a8;
  --pink: #f2527f;
  --berry: #c92e5b;
  --mint: #35b58a;
  --mint-deep: #17775a;
  --blue: #2f93d0;
  --link: #1a6fa6;
  --orange: #f27a3a;
  --on-ink: #d6e8ef;
  --on-ink-soft: #a9c6d1;

  --display: "Shrikhand", "Bricolage Grotesque", Georgia, serif;
  --text: "Bricolage Grotesque", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --r-tile: 18px;
  --r-ctl: 14px;
  --wrap: 1180px;
  --gut: clamp(16px, 4vw, 32px);
  --line: 2px solid var(--ink);
  --lift: 0 4px 0 var(--ink);
}

/* kolory kafelków – wybierane klasą (tone() w widokach) */
.t0 { --tile: #ffe9a8; --tile-d: #ffc933; }
.t1 { --tile: #cbe7f7; --tile-d: #2f93d0; }
.t2 { --tile: #ffd1dc; --tile-d: #f2527f; }
.t3 { --tile: #bfebda; --tile-d: #35b58a; }
.t4 { --tile: #ffd5b8; --tile-d: #f27a3a; }
.t5 { --tile: #dad4fa; --tile-d: #8e7cf0; }

/* ---------- baza ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--text);
  font-size: 1.0625rem;
  line-height: 1.55;
  color: var(--ink);
  background-color: var(--foam);
  /* delikatna siatka fug – cały sklep stoi na „ścianie z kafelków” */
  background-image: linear-gradient(var(--grout) 2px, transparent 2px), linear-gradient(90deg, var(--grout) 2px, transparent 2px);
  background-size: 64px 64px;
  background-position: -1px -1px;
}
main { flex: 1 0 auto; }
img, svg { max-width: 100%; }
img { height: auto; }
h1, h2, h3, h4 { margin: 0 0 .5em; line-height: 1.15; }
h1 { font-family: var(--display); font-weight: 400; font-size: clamp(2rem, 5vw, 3.1rem); }
.quote { font-family: var(--text); font-weight: 800; } /* cudzysłów w czcionce nagłówków jest źle narysowany – używamy tekstowej */
h2 { font-family: var(--display); font-weight: 400; font-size: clamp(1.55rem, 3.2vw, 2.25rem); }
h3 { font-size: 1.2rem; font-weight: 700; }
p { margin: 0 0 1em; }
a { color: var(--link); text-underline-offset: .18em; text-decoration-thickness: 2px; }
a:hover { color: var(--ink); }
ul, ol { padding-left: 1.2rem; }
hr { border: 0; border-top: 2px solid var(--grout); margin: 1.6rem 0; }
small, .small { font-size: .9rem; }
.muted { color: var(--muted); }
strong, b { font-weight: 700; }

:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; border-radius: 6px; }
.on-dark :focus-visible, .site-footer :focus-visible, .announce :focus-visible { outline-color: var(--butter); }

.skip { position: absolute; left: 8px; top: -60px; z-index: 100; background: var(--ink); color: var(--white); padding: .6rem 1rem; border-radius: 10px; }
.skip:focus { top: 8px; }

.wrap { width: 100%; max-width: calc(var(--wrap) + var(--gut) * 2); margin-inline: auto; padding-inline: var(--gut); }
.narrow { max-width: 760px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.hp { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }
[hidden] { display: none !important; }
.ico { width: 1.25em; height: 1.25em; flex: none; vertical-align: -.2em; }
.stack > * + * { margin-top: 1rem; }
.center-text { text-align: center; }

/* ---------- przyciski ---------- */
.btn {
  --b-bg: var(--butter); --b-fg: var(--ink);
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .72rem 1.25rem;
  font: inherit; font-weight: 700; line-height: 1.1; text-align: center; text-decoration: none;
  color: var(--b-fg); background: var(--b-bg);
  border: var(--line); border-radius: var(--r-ctl);
  box-shadow: var(--lift);
  cursor: pointer;
  transition: transform .12s ease, box-shadow .12s ease, background-color .12s ease;
}
.btn:hover { color: var(--b-fg); transform: translateY(-2px); box-shadow: 0 6px 0 var(--ink); }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--ink); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; transform: none; box-shadow: 0 2px 0 var(--ink); }
.btn--ink { --b-bg: var(--ink); --b-fg: var(--white); box-shadow: 0 4px 0 var(--blue); }
.btn--ink:hover { box-shadow: 0 6px 0 var(--blue); }
.btn--ghost { --b-bg: var(--white); }
.btn--pink { --b-bg: var(--pink); }
.btn--danger { --b-bg: var(--white); --b-fg: var(--berry); border-color: var(--berry); box-shadow: 0 4px 0 var(--berry); }
.btn--sm { padding: .5rem .9rem; font-size: .95rem; border-radius: 12px; box-shadow: 0 3px 0 var(--ink); }
.btn--lg { padding: .95rem 1.7rem; font-size: 1.1rem; }
.btn--block { display: flex; width: 100%; }
.link-btn { background: none; border: 0; padding: 0; font: inherit; color: var(--link); text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: .18em; cursor: pointer; }
.link-btn:hover { color: var(--ink); }

/* ---------- formularze ---------- */
.field { margin-bottom: 1rem; }
.field > label, .label { display: block; margin-bottom: .3rem; font-weight: 700; font-size: .98rem; }
.input, select.input, textarea.input {
  width: 100%;
  padding: .72rem .9rem;
  font: inherit; color: var(--ink);
  background: var(--white);
  border: var(--line); border-radius: 12px;
  appearance: none;
}
select.input {
  padding-right: 2.4rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='m6 9 6 6 6-6' fill='none' stroke='%230f3a4b' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right .7rem center; background-size: 1.1rem;
}
textarea.input { min-height: 7.5rem; resize: vertical; }
.input::placeholder { color: #6f8791; }
.input:focus { outline: none; box-shadow: 0 0 0 4px var(--butter); }
.input:focus-visible { outline: none; }
.field.is-bad .input { border-color: var(--berry); }
.field__err { margin: .35rem 0 0; color: var(--berry); font-weight: 600; font-size: .93rem; }
.field__hint { margin: .3rem 0 0; color: var(--muted); font-size: .9rem; }
.row { display: grid; gap: 0 1rem; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.row--2 { grid-template-columns: 1fr 1fr; }
.row--zip { grid-template-columns: minmax(110px, 1fr) 2fr; }
.check { display: flex; gap: .65rem; align-items: flex-start; margin-bottom: .8rem; cursor: pointer; line-height: 1.4; }
.check input { flex: none; width: 1.3rem; height: 1.3rem; margin: .1rem 0 0; accent-color: var(--ink); cursor: pointer; }
.check.is-bad span { color: var(--berry); }
.pw { position: relative; }
.pw .input { padding-right: 3.2rem; }
.pw__toggle { position: absolute; right: .35rem; top: 50%; transform: translateY(-50%); width: 2.4rem; height: 2.4rem; display: grid; place-items: center; background: none; border: 0; border-radius: 10px; color: var(--ink); cursor: pointer; }
.pw__toggle:hover { background: var(--butter-soft); }
.meter { height: 8px; border-radius: 99px; background: var(--grout); overflow: hidden; margin-top: .5rem; }
.meter > i { display: block; height: 100%; width: 25%; background: var(--berry); transition: width .2s, background-color .2s; }
.meter[data-level="2"] > i { width: 50%; background: var(--orange); }
.meter[data-level="3"] > i { width: 75%; background: var(--butter); }
.meter[data-level="4"] > i { width: 100%; background: var(--mint); }

/* wybór „kafelkiem” (dostawa, płatność) */
.choices { display: grid; gap: .6rem; margin-bottom: 1rem; }
.choice { display: flex; gap: .8rem; align-items: center; padding: .85rem 1rem; background: var(--white); border: var(--line); border-radius: 14px; cursor: pointer; }
.choice:hover { background: var(--foam); }
.choice:has(input:checked) { background: var(--butter-soft); box-shadow: 0 3px 0 var(--ink); transform: translateY(-1px); }
.choice:has(input:focus-visible) { outline: 3px solid var(--ink); outline-offset: 3px; }
.choice input { flex: none; width: 1.25rem; height: 1.25rem; accent-color: var(--ink); }
.choice__main { flex: 1; min-width: 0; }
.choice__main strong { display: block; }
.choice__main small { color: var(--muted); }
.choice__price { font-weight: 800; white-space: nowrap; }

/* ---------- komunikaty ---------- */
.flashes { padding-top: 1rem; display: grid; gap: .6rem; }
.flash, .notice {
  display: flex; gap: .7rem; align-items: flex-start;
  padding: .8rem 1rem; border: var(--line); border-radius: 14px;
  background: var(--sky); font-weight: 600;
}
.flash .ico, .notice .ico { margin-top: .12rem; }
.flash--ok { background: #bfebda; }
.flash--error, .notice--error { background: #ffd1dc; }
.notice--warn { background: var(--butter-soft); }
.flash__close { margin-left: auto; background: none; border: 0; padding: .1rem .3rem; cursor: pointer; color: var(--ink); border-radius: 8px; }
.flash__close:hover { background: rgba(255, 255, 255, .6); }
.notice { margin-bottom: 1rem; font-weight: 500; }
.notice--error { font-weight: 600; }

.toast {
  position: fixed; left: 50%; bottom: 1.2rem; z-index: 90;
  opacity: 0; visibility: hidden; pointer-events: none;
  transform: translate(-50%, 200%);
  max-width: min(92vw, 460px);
  padding: .8rem 1.1rem; border-radius: 14px; border: 2px solid var(--butter);
  background: var(--ink); color: var(--white); font-weight: 600;
  box-shadow: 0 10px 30px rgba(15, 58, 75, .35);
  transition: transform .3s cubic-bezier(.2, .9, .3, 1.2), opacity .2s, visibility 0s .3s;
}
.toast.is-on { opacity: 1; visibility: visible; pointer-events: auto; transform: translate(-50%, 0); transition-delay: 0s; }
.toast.is-bad { border-color: var(--pink); }
.toast a { color: var(--butter); }

/* ---------- nagłówek ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--white); border-bottom: var(--line); }
.aisles { border-bottom: 2px solid var(--grout); }
.announce { background: var(--ink); color: var(--butter); text-align: center; font-weight: 600; font-size: .93rem; padding: .45rem 1rem; }
.announce a { color: var(--butter); }
.bar { display: flex; align-items: center; flex-wrap: wrap; gap: .6rem 1.2rem; padding-block: .7rem; }
.brand { display: inline-flex; align-items: center; gap: .55rem; text-decoration: none; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand svg { color: var(--butter); width: 46px; height: 46px; flex: none; transition: transform .25s cubic-bezier(.2, .9, .3, 1.4); }
.brand:hover svg { transform: rotate(-8deg) scale(1.06); }
.brand span { font-family: var(--display); font-size: 1.75rem; line-height: 1; }
.search { flex: 1 1 260px; display: flex; max-width: 520px; margin-inline: auto; }
.search .input { border-radius: 12px 0 0 12px; border-right: 0; padding-block: .6rem; }
.search button { flex: none; width: 3.2rem; display: grid; place-items: center; background: var(--butter); border: var(--line); border-radius: 0 12px 12px 0; cursor: pointer; color: var(--ink); }
.search button:hover { background: var(--ink); color: var(--butter); }
.tools { display: flex; gap: .3rem; margin-left: auto; }
.tool { position: relative; display: inline-flex; align-items: center; gap: .45rem; padding: .5rem .8rem; border: 2px solid transparent; border-radius: 12px; color: var(--ink); font-weight: 700; text-decoration: none; background: none; font-family: inherit; font-size: 1rem; cursor: pointer; }
.tool:hover { border-color: var(--ink); background: var(--butter-soft); color: var(--ink); }
.tool .ico { width: 1.5rem; height: 1.5rem; }
.count { position: absolute; top: -.35rem; right: -.2rem; min-width: 1.45rem; height: 1.45rem; padding: 0 .3rem; display: grid; place-items: center; border: 2px solid var(--ink); border-radius: 99px; background: var(--pink); color: var(--ink); font-size: .78rem; font-weight: 800; line-height: 1; }
.count[data-n="0"] { display: none; }
@media (min-width: 641px) {
  /* gdy widać napis „Koszyk”, licznik stoi obok niego zamiast zasłaniać literę */
  .tool .count { position: static; margin-left: .05rem; }
}
.count.pop { animation: pop .5s cubic-bezier(.2, .9, .3, 1.6); }
@keyframes pop { 0% { transform: scale(1); } 40% { transform: scale(1.7) rotate(-8deg); } 100% { transform: scale(1); } }
.tools form { margin: 0; }

.aisles { background: var(--foam); }
.aisles ul { display: flex; gap: .5rem; margin: 0; padding: .55rem var(--gut); list-style: none; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.aisles ul::-webkit-scrollbar { display: none; }
.aisles a { display: inline-flex; white-space: nowrap; padding: .38rem .95rem; border: var(--line); border-radius: 99px; background: var(--tile, var(--white)); color: var(--ink); font-weight: 600; font-size: .95rem; text-decoration: none; transition: transform .12s, box-shadow .12s; }
.aisles a:hover, .aisles a[aria-current="page"] { transform: translateY(-1px); box-shadow: 0 3px 0 var(--ink); background: var(--tile-d, var(--butter)); }
.aisles a[aria-current="page"] { background: var(--ink); color: var(--white); }

/* ---------- stopka ---------- */
.trim { height: 16px; margin-top: 3.2rem; background-color: var(--foam);
  background-image:
    repeating-linear-gradient(90deg, transparent 0 33px, var(--foam) 33px 36px),
    repeating-linear-gradient(90deg, var(--butter) 0 36px, var(--sky) 36px 72px, var(--pink) 72px 108px, var(--mint) 108px 144px, var(--orange) 144px 180px, #dad4fa 180px 216px);
  border-block: var(--line);
}
.site-footer { background: var(--ink); color: var(--on-ink); }
.site-footer a { color: var(--white); text-decoration-color: rgba(255, 255, 255, .35); }
.site-footer a:hover { color: var(--butter); }
.site-footer .link-btn { color: var(--white); text-decoration-color: rgba(255, 255, 255, .35); }
.site-footer .link-btn:hover { color: var(--butter); }
.site-footer form { margin: 0; }
.foot { display: grid; gap: 2rem; grid-template-columns: 1.4fr repeat(3, 1fr); padding-block: 2.6rem 1.8rem; }
.foot h3 { margin-bottom: .6rem; font-size: 1.05rem; color: var(--butter); }
.foot ul { list-style: none; margin: 0; padding: 0; }
.foot li { margin-bottom: .4rem; }
.foot__brand { display: flex; align-items: center; gap: .6rem; font-family: var(--display); font-size: 1.9rem; color: var(--white); margin-bottom: .6rem; }
.foot__brand svg { width: 48px; height: 48px; color: var(--butter); }
.foot p { margin-bottom: .6rem; }
.foot-legal { border-top: 1px solid rgba(255, 255, 255, .18); padding-block: 1.1rem 1.6rem; font-size: .9rem; color: var(--on-ink-soft); display: flex; flex-wrap: wrap; gap: .4rem 1.5rem; justify-content: space-between; }

/* ---------- kafelki i naklejki ---------- */
.tile { position: relative; isolation: isolate; overflow: hidden; background: var(--tile, var(--white)); border: var(--line); border-radius: var(--r-tile); }
.tile::before { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; background: linear-gradient(135deg, rgba(255, 255, 255, .55) 0 13%, transparent 13.5%), linear-gradient(0deg, rgba(15, 58, 75, .07), transparent 22%); }
.art { display: block; width: 100%; height: 100%; transition: transform .35s cubic-bezier(.2, .9, .3, 1.4); }
.sticker { position: relative; display: inline-grid; place-items: center; width: 7.6rem; height: 7.6rem; text-align: center; transform: rotate(-9deg); color: var(--ink); }
.sticker svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.sticker span { position: relative; font-family: var(--display); font-size: 1.7rem; line-height: 1; padding: 0 .5rem; }
.sticker--sm { width: 4.2rem; height: 4.2rem; }
.sticker--sm span { font-size: .98rem; }
.stamp { display: inline-block; padding: .2rem .6rem; background: var(--ink); color: var(--butter); border-radius: 8px; font-weight: 800; font-size: .82rem; transform: rotate(-3deg); }

/* ---------- karta produktu ---------- */
.grid { display: grid; gap: 1.1rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 235px), 1fr)); }
.card { position: relative; display: flex; flex-direction: column; background: var(--white); border: var(--line); border-radius: 20px; transition: transform .15s ease, box-shadow .15s ease; }
.card:hover { transform: translateY(-4px); box-shadow: 0 7px 0 var(--tile-d, var(--ink)); }
.card__img { position: relative; display: block; aspect-ratio: 1; background: var(--tile, var(--sky)); border-radius: 18px 18px 0 0; border-bottom: var(--line); overflow: hidden; }
.card__img img { width: 100%; height: 100%; object-fit: contain; padding: 7%; transition: transform .3s cubic-bezier(.2, .9, .3, 1.3); }
.card:hover .card__img img { transform: scale(1.05) rotate(-1.5deg); }
.card__tags { position: absolute; left: .6rem; top: .6rem; display: flex; flex-direction: column; align-items: flex-start; gap: .35rem; }
.card__sale { position: absolute; right: .4rem; top: .4rem; }
.card__body { display: flex; flex-direction: column; flex: 1; padding: .9rem 1rem 1rem; }
.card__name { margin: 0 0 .15rem; font-size: 1.08rem; line-height: 1.25; font-weight: 700; }
.card__name a { color: var(--ink); text-decoration: none; }
.card__name a::after { content: ""; position: absolute; inset: 0; border-radius: 20px; } /* cała karta klikalna */
.card__meta { margin: 0 0 .7rem; color: var(--muted); font-size: .92rem; }
.card__buy { margin-top: auto; display: flex; flex-direction: column; align-items: stretch; gap: .6rem; }
.card__buy form { position: relative; z-index: 2; margin: 0; }
.card__buy .btn { width: 100%; }
.card__buy .soldout { text-align: center; }
.price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 0 .5rem; margin: 0; line-height: 1.1; }
.price strong { font-family: var(--display); font-weight: 400; font-size: 1.45rem; }
.price s { color: var(--muted); font-size: .95rem; }
.price--sale strong { color: var(--berry); }
.card__price { display: flex; flex-direction: column; gap: .2rem; }
.unit { margin: 0; color: var(--muted); font-size: .84rem; font-weight: 600; line-height: 1.25; }
/* informacja wymagana przy obniżce: stały tekst „Najniższa cena z 30 dni przed obniżką” + kwota */
.omnibus { margin: 0; color: var(--ink-soft); font-size: .78rem; line-height: 1.3; }
.omnibus s { color: var(--ink); font-weight: 700; text-decoration-thickness: 1px; }
.omnibus--lg { margin: .1rem 0 .15rem; font-size: .95rem; }
.unit--lg { margin: 0 0 .6rem; font-size: .98rem; }
.pre { white-space: pre-line; }
.hazard__type { margin-bottom: .5rem; }
.maker { margin: 1.2rem 0; padding: .9rem 1.1rem; background: var(--white); border: 2px solid var(--grout); border-radius: 16px; }
.maker h3 { margin: 0 0 .35rem; font-size: 1rem; }
.maker p { margin: 0; color: var(--ink-soft); overflow-wrap: anywhere; }
.soldout { display: inline-block; padding: .35rem .7rem; border: 2px dashed var(--muted); border-radius: 10px; color: var(--muted); font-weight: 700; font-size: .9rem; }

/* ---------- paginacja i okruszki ---------- */
.pager { display: flex; flex-wrap: wrap; gap: .45rem; justify-content: center; margin: 2rem 0 0; padding: 0; list-style: none; }
.pager a, .pager span { display: grid; place-items: center; min-width: 2.7rem; height: 2.7rem; padding: 0 .8rem; border: var(--line); border-radius: 12px; background: var(--white); color: var(--ink); font-weight: 700; text-decoration: none; }
.pager a:hover { background: var(--butter-soft); box-shadow: 0 3px 0 var(--ink); transform: translateY(-1px); }
.pager [aria-current="page"] { background: var(--ink); color: var(--white); }
.pager .gap { border: 0; background: none; min-width: 1.4rem; padding: 0; }
.crumbs { margin: 0 0 1rem; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: .2rem .5rem; font-size: .93rem; color: var(--muted); }
.crumbs li + li::before { content: "/"; margin-right: .5rem; color: var(--muted); }
.crumbs a { color: var(--ink); }

/* ---------- ilość ---------- */
.qty { display: inline-flex; align-items: stretch; border: var(--line); border-radius: 12px; background: var(--white); overflow: hidden; }
.qty button { width: 2.6rem; display: grid; place-items: center; background: var(--butter-soft); border: 0; color: var(--ink); cursor: pointer; font: inherit; }
.qty button:hover { background: var(--butter); }
.qty input { width: 3.1rem; padding: .5rem 0; border: 0; border-inline: var(--line); text-align: center; font: inherit; font-weight: 700; color: var(--ink); background: var(--white); -moz-appearance: textfield; appearance: textfield; }
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.qty input:focus { outline: none; background: var(--butter-soft); }
.js .qty-save { display: none; }

/* ---------- panele, tabele ---------- */
.panel { background: var(--white); border: var(--line); border-radius: 22px; padding: clamp(1.1rem, 3vw, 1.7rem); box-shadow: 0 6px 0 var(--tile-d, var(--ink)); }
.panel > :last-child { margin-bottom: 0; }
.panel h2, .panel h3 { margin-bottom: .6rem; }
.table-wrap { position: relative; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.table { width: 100%; border-collapse: collapse; font-size: .98rem; }
.table th, .table td { padding: .65rem .7rem; text-align: left; border-bottom: 2px solid var(--grout); vertical-align: middle; }
.table th { font-size: .9rem; color: var(--muted); font-weight: 700; white-space: nowrap; }
.table .num { text-align: right; white-space: nowrap; }
.pill { display: inline-block; padding: .15rem .65rem; border: 2px solid var(--ink); border-radius: 99px; background: var(--sky); font-weight: 700; font-size: .85rem; white-space: nowrap; }
.pill--new { background: var(--butter-soft); }
.pill--paid, .pill--delivered { background: #bfebda; }
.pill--processing, .pill--shipped { background: var(--sky); }
.pill--cancelled { background: #ffd1dc; }

/* ---------- ostrzeżenia (chemia!) ---------- */
.hazard { margin: 1.2rem 0; border: var(--line); border-radius: 16px; overflow: hidden; background: #fff6d6; }
.hazard::before { content: ""; display: block; height: 12px; background: repeating-linear-gradient(-45deg, var(--butter) 0 12px, var(--ink) 12px 24px); border-bottom: var(--line); }
.hazard > div { padding: .9rem 1.1rem; }
.hazard h3 { display: flex; gap: .5rem; align-items: center; margin-bottom: .4rem; }
.hazard p:last-child { margin-bottom: 0; }

/* ---------- bąbelki (reakcja na dodanie do koszyka) ---------- */
.bubble { position: fixed; z-index: 95; width: 14px; height: 14px; border-radius: 50%; pointer-events: none; background: rgba(255, 255, 255, .75); border: 2px solid var(--blue); animation: rise .9s ease-out forwards; }
@keyframes rise { to { transform: translate(var(--dx, 0), -90px) scale(1.5); opacity: 0; } }

/* ---------- ruch ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-delay: 0s !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; transition-delay: 0s !important; scroll-behavior: auto !important; }
}

/* ---------- responsywność układu ogólnego ---------- */
@media (max-width: 860px) {
  .foot { grid-template-columns: 1fr 1fr; }
  .foot > :first-child { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  body { font-size: 1rem; }
  .site-header { position: static; }
  .bar { gap: .5rem; padding-block: .55rem; }
  .brand svg { width: 40px; height: 40px; }
  .brand span { font-size: 1.5rem; }
  .search { order: 3; flex-basis: 100%; max-width: none; }
  .tool .label-text { display: none; }
  .tool { padding: .45rem .55rem; }
  .row--2, .row--zip { grid-template-columns: 1fr; }
  .foot { grid-template-columns: 1fr; gap: 1.4rem; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .7rem; }
  .card__body { padding: .7rem .75rem .8rem; }
  .card__name { font-size: .98rem; }
  .price strong { font-size: 1.25rem; }
  .sticker:not(.sticker--sm) { width: 6.2rem; height: 6.2rem; }
  .card__buy .btn { padding: .55rem .6rem; font-size: .92rem; }
}

/* ---------- telefon i ekrany dotykowe: cele dotyku o wysokości ok. 44 px ---------- */
@media (pointer: coarse), (max-width: 760px) {
  .link-btn { display: inline-flex; align-items: center; min-height: 2.75rem; padding-inline: .25rem; }
  .check { padding-block: .7rem; margin-bottom: 0; }
  .foot li { margin-bottom: 0; }
  .foot li a, .foot p a { display: inline-block; padding-block: .6rem; }
  .btn { min-height: 2.75rem; }
  .aisles a { align-items: center; min-height: 2.75rem; }
  .crumbs { gap: 0 .5rem; }
  .crumbs a { display: inline-block; padding: .6rem .2rem; }
  .pw__toggle { width: 2.75rem; height: 2.75rem; }
  .back a { display: inline-block; padding-block: .7rem; }
}
@media (max-width: 380px) {
  .card__body { padding-inline: .55rem; }
  .card__buy .btn { gap: .3rem; padding-inline: .3rem; font-size: .88rem; white-space: nowrap; }
  .card__buy .btn .ico { width: 1.15rem; height: 1.15rem; }
}

/* ---------- własne logo (panel: Wygląd strony) ---------- */
.brand--img img { display: block; width: auto; max-width: min(56vw, 300px); object-fit: contain; }
.brand--s img { height: 32px; }
.brand--m img { height: 44px; }
.brand--l img { height: 60px; }
.foot__logo { display: inline-flex; padding: .35rem .65rem; background: var(--white); border-radius: 12px; }
.foot__logo img { display: block; width: auto; height: 44px; max-width: 220px; object-fit: contain; }
@media (max-width: 640px) {
  .brand--s img { height: 28px; }
  .brand--m img { height: 36px; }
  .brand--l img { height: 46px; }
  .brand--img img { max-width: 52vw; }
}

/* ==========================================================================
   Wygoda klienta: podpowiedzi w wyszukiwarce, dolne paski na telefonie, toast z postępem dostawy
   ========================================================================== */

/* ---------- podpowiedzi w wyszukiwarce ---------- */
.search { position: relative; }
.suggest { position: absolute; left: 0; right: 0; top: calc(100% + 8px); z-index: 70; max-height: min(70vh, 30rem); overflow-y: auto; overscroll-behavior: contain; background: var(--white); border: var(--line); border-radius: 18px; box-shadow: 0 7px 0 var(--ink); }
.suggest ul { margin: 0; padding: .35rem; list-style: none; }
.sg__item { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; align-items: center; gap: .7rem; min-height: 3.1rem; padding: .4rem .55rem; border-radius: 12px; color: var(--ink); text-decoration: none; }
.sg__item:hover, .suggest li.is-active > .sg__item { background: var(--butter-soft); color: var(--ink); }
.sg__item img { width: 44px; height: 44px; object-fit: cover; border: 2px solid var(--ink); border-radius: 10px; background: var(--foam); }
.sg__txt { display: grid; gap: .1rem; min-width: 0; }
.sg__name { font-weight: 700; line-height: 1.2; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sg__meta { color: var(--muted); font-size: .85rem; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sg__price { font-weight: 800; white-space: nowrap; }
.sg__tag { display: inline-block; padding: 0 .4rem; border-radius: 99px; background: var(--pink); color: var(--ink); font-size: .75rem; font-weight: 800; vertical-align: .08em; }
.sg__cat { grid-template-columns: minmax(0, 1fr) auto; }
.sg__cat .sg__txt { font-weight: 700; }
.sg__all { display: block; margin-top: .15rem; padding-block: .75rem; text-align: center; font-weight: 800; border-top: 2px solid var(--grout); border-radius: 0 0 12px 12px; }
.sg__none { padding: .9rem .8rem; color: var(--ink-soft); font-weight: 500; }

/* ---------- dolny pasek menu (telefon) ---------- */
.tabbar { display: none; }
.stickybar { display: none; }
@media (max-width: 760px) {
  .tabbar { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; background: var(--white); border-top: var(--line); padding-bottom: env(safe-area-inset-bottom); box-shadow: 0 -6px 18px rgba(15, 58, 75, .1); }
  .tabbar a { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .15rem; min-height: 3.6rem; padding: .4rem .15rem; color: var(--ink-soft); font-size: .74rem; font-weight: 700; line-height: 1.1; text-decoration: none; }
  .tabbar a:hover { color: var(--ink); }
  .tabbar .ico { width: 1.55rem; height: 1.55rem; }
  .tabbar a[aria-current="page"] { color: var(--ink); }
  .tabbar a[aria-current="page"]::before { content: ""; position: absolute; top: -2px; left: 24%; right: 24%; height: 4px; border-radius: 0 0 4px 4px; background: var(--ink); }
  .tabbar .count { top: .3rem; right: auto; left: calc(50% + .3rem); }

  /* pasek z ceną/kwotą i głównym przyciskiem: pojawia się, gdy przycisk na stronie zniknie z widoku */
  html.js .stickybar.is-on { display: flex; animation: bar-up .22s ease-out; }
  .stickybar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; align-items: center; justify-content: space-between; gap: .8rem; padding: .55rem var(--gut) calc(.55rem + env(safe-area-inset-bottom)); background: var(--white); border-top: var(--line); box-shadow: 0 -6px 18px rgba(15, 58, 75, .12); }
  .stickybar__info { display: grid; min-width: 0; line-height: 1.15; }
  .stickybar__info strong { font-family: var(--display); font-weight: 400; font-size: 1.5rem; }
  .stickybar__info s, .stickybar__info small { color: var(--muted); font-size: .85rem; }
  .stickybar .btn { flex: 0 1 auto; white-space: nowrap; }

  /* miejsce na dole strony, żeby stopka nie chowała się pod paskiem */
  body:not(.no-tabbar) .site-footer { padding-bottom: calc(3.8rem + env(safe-area-inset-bottom)); }
  body.has-sticky .site-footer { padding-bottom: calc(4.8rem + env(safe-area-inset-bottom)); }
  /* komunikaty nad paskiem */
  body:not(.no-tabbar) .toast { bottom: calc(4.6rem + env(safe-area-inset-bottom)); }
  body.has-sticky .toast { bottom: calc(5.4rem + env(safe-area-inset-bottom)); }
}
@keyframes bar-up { from { transform: translateY(100%); } to { transform: translateY(0); } }
/* gdy na ekranie jest klawiatura, paski tylko przeszkadzają */
html.kb .tabbar, html.kb .stickybar { display: none !important; }

/* ---------- toast: dodatkowa linijka i postęp do darmowej dostawy ---------- */
.toast { display: grid; gap: .35rem; width: max-content; }
.toast__sub { font-weight: 500; font-size: .93rem; color: var(--on-ink); }
.toast__bar { display: block; width: 100%; height: 10px; appearance: none; border: 2px solid var(--white); border-radius: 99px; background: transparent; overflow: hidden; }
.toast__bar::-webkit-progress-bar { background: transparent; }
.toast__bar::-webkit-progress-value { background: var(--mint); border-radius: 99px; }
.toast__bar::-moz-progress-bar { background: var(--mint); }
