/* =============================================================================
   Gadget Soko — storefront styles
   Brand colours sampled from the logo: red #DC0A0A · blue #03389A
   ========================================================================== */

:root {
  --red: #e10b0b;
  --red-600: #c40808;
  --red-700: #a00606;
  --red-50: #fff1f1;
  --red-100: #ffe1e1;

  --blue: #0a3a9c;
  --blue-600: #0b46bb;
  --blue-700: #072d7a;
  --blue-800: #06225e;
  --blue-900: #061a47;
  --blue-50: #eef3ff;
  --blue-100: #dce6fb;

  --wa: #13853c;          /* WhatsApp green, darkened so white text passes contrast */
  --wa-600: #0f6f32;
  --wa-bright: #25d366;

  --ink: #0d1630;
  --ink-2: #2a3450;
  --muted: #5b6480;
  --line: #e3e8f1;
  --line-2: #cdd5e4;
  --bg: #f4f6fb;
  --surface: #ffffff;
  --warn: #8a5a00;
  --warn-bg: #fff6dd;

  --radius-sm: 10px;
  --radius: 14px;
  --radius-lg: 22px;
  --shadow-sm: 0 1px 2px rgba(13, 22, 48, .06), 0 1px 1px rgba(13, 22, 48, .04);
  --shadow: 0 8px 24px -10px rgba(13, 22, 48, .18);
  --shadow-lg: 0 24px 48px -16px rgba(13, 22, 48, .32);

  --font: "Barlow", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --display: "Barlow Condensed", "Arial Narrow", "Roboto Condensed", Impact, sans-serif;

  --header-h: 128px;
  --bottom-nav-h: 0px;
  --gutter: clamp(16px, 4vw, 32px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 12px); }
body {
  margin: 0;
  font: 400 16px/1.5 var(--font);
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  padding-bottom: var(--bottom-nav-h);
}
img, svg { display: block; max-width: 100%; }
a { color: var(--blue); text-decoration: none; }
a:hover { color: var(--blue-600); }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, h4 { margin: 0; line-height: 1.15; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid rgba(10, 58, 156, .45); outline-offset: 2px; border-radius: 6px; }
[hidden] { display: none !important; }

.container { width: 100%; max-width: 1320px; margin-inline: auto; padding-inline: var(--gutter); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 2000; background: var(--blue); color: #fff; padding: 10px 14px; border-radius: 8px; }
.skip-link:focus { top: 12px; color: #fff; }
.icon { width: 1.25em; height: 1.25em; flex: none; }

/* ----------------------------------------------------------------------------
   Page loader — redraws the logo: mouse clicks, the cable carries the signal,
   the cart rolls off with its wheels spinning.
   ------------------------------------------------------------------------- */
.loader {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: grid;
  place-items: center;
  background:
    radial-gradient(60% 50% at 50% 40%, rgba(10, 58, 156, .07), transparent 70%),
    #fff;
  transition: opacity .45s ease, visibility .45s;
}
.loader__inner { display: flex; flex-direction: column; align-items: center; padding: 24px; }
.loader__mark { width: min(300px, 72vw); height: auto; overflow: visible; }

.loader-quick .loader { opacity: 0; animation: ld-appear .25s ease .35s forwards; }
.loader.is-hidden { opacity: 0 !important; visibility: hidden; animation: none; pointer-events: none; }
.loader.is-leaving { opacity: 1; visibility: visible; animation: none; transition-delay: .12s; }
@keyframes ld-appear { to { opacity: 1; } }

.ld-red { fill: var(--red); }
.ld-white { fill: #fff; }
.ld-cut { fill: none; stroke: #fff; stroke-width: 2.6; stroke-linecap: round; }
.ld-wheel-rim { stroke: #fff; stroke-width: 2.5; }
.ld-handle { fill: none; stroke: var(--red); stroke-width: 9; stroke-linecap: round; }
.ld-cable {
  fill: none; stroke: var(--red); stroke-width: 3.2; stroke-linecap: round;
  stroke-dasharray: 100; stroke-dashoffset: 100;
  animation: ld-cable 2.4s cubic-bezier(.6, .05, .3, 1) infinite;
}
@keyframes ld-cable {
  0% { stroke-dashoffset: 100; }
  38%, 68% { stroke-dashoffset: 0; }
  100% { stroke-dashoffset: -100; }
}
.ld-mouse { transform-box: fill-box; transform-origin: center; animation: ld-click 2.4s ease infinite; }
@keyframes ld-click { 0%, 14%, 100% { transform: scale(1); } 5% { transform: scale(.9) rotate(-3deg); } }
.ld-ripple {
  fill: none; stroke: var(--red); stroke-width: 2; opacity: 0;
  transform-box: fill-box; transform-origin: center;
  animation: ld-ripple 2.4s ease-out infinite;
}
@keyframes ld-ripple { 0% { opacity: 0; transform: scale(.3); } 6% { opacity: .7; } 32%, 100% { opacity: 0; transform: scale(2.4); } }
.ld-cart { transform-box: fill-box; transform-origin: 50% 100%; animation: ld-bob 2.4s ease-in-out infinite; }
@keyframes ld-bob {
  0%, 34% { transform: translate(0, 0) rotate(0); }
  40% { transform: translate(-3px, -3px) rotate(-3deg); }      /* jolt when the signal arrives */
  46%, 56%, 66%, 76%, 86% { transform: translate(0, -1.5px) rotate(-.5deg); }
  51%, 61%, 71%, 81%, 91% { transform: translate(0, 0) rotate(0); }
}
.ld-wheel { transform-box: fill-box; transform-origin: center; animation: ld-spin .8s linear infinite; }
@keyframes ld-spin { to { transform: rotate(-360deg); } }
.ld-speed path { fill: none; stroke: var(--blue); stroke-width: 3.2; stroke-linecap: round; opacity: 0; animation: ld-speed .9s ease-in infinite; }
.ld-speed path:nth-child(2) { animation-delay: .18s; }
.ld-speed path:nth-child(3) { animation-delay: .36s; }
@keyframes ld-speed { 0% { opacity: 0; transform: translateX(-8px); } 30% { opacity: .85; } 100% { opacity: 0; transform: translateX(16px); } }

.loader__word {
  display: flex; align-items: baseline; margin-top: 6px;
  font: 800 clamp(36px, 8vw, 54px)/1 var(--display);
  color: var(--blue); letter-spacing: .01em;
  text-shadow: 0 2px 0 rgba(6, 26, 71, .18), 0 6px 14px rgba(6, 26, 71, .12);
}
.loader__word span, .loader__word em {
  display: inline-block; opacity: 0; transform: translateY(14px) scale(.9);
  animation: ld-letter .5s cubic-bezier(.2, .9, .3, 1.35) forwards;
  animation-delay: calc(var(--i) * 45ms + .15s);
}
.loader__word .sp { width: .28em; }
.loader__word em { font-style: normal; color: var(--red); font-size: .72em; }
@keyframes ld-letter { to { opacity: 1; transform: none; } }
.loader__tag {
  display: flex; align-items: center; gap: 10px; margin-top: 10px;
  color: var(--blue); font: 700 12px/1 var(--font); letter-spacing: .24em; text-transform: uppercase;
  opacity: 0; animation: ld-fade .5s ease .75s forwards;
}
.loader__tag i { display: block; height: 2px; width: 0; background: var(--blue); border-radius: 2px; animation: ld-line .5s ease .85s forwards; }
@keyframes ld-fade { to { opacity: 1; } }
@keyframes ld-line { to { width: 30px; } }
.loader__bar { width: 190px; height: 4px; margin-top: 24px; border-radius: 4px; background: var(--blue-50); overflow: hidden; }
.loader__bar span { display: block; width: 40%; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--red), var(--blue)); animation: ld-bar 1.1s ease-in-out infinite; }
@keyframes ld-bar { from { transform: translateX(-100%); } to { transform: translateX(260%); } }

@media (prefers-reduced-motion: reduce) {
  .loader *, .loader { animation: none !important; }
  .ld-cable { stroke-dashoffset: 0; }
  .loader__word span, .loader__word em, .loader__tag { opacity: 1; transform: none; }
  .loader__tag i { width: 30px; }
}

/* htmx request bar */
.progress {
  position: fixed; inset: 0 0 auto; height: 3px; z-index: 2500; pointer-events: none;
  background: linear-gradient(90deg, var(--red), var(--blue));
  transform: scaleX(0); transform-origin: left; opacity: 0;
}
.is-loading .progress { opacity: 1; animation: progress 1.6s cubic-bezier(.1, .7, .3, 1) forwards; }
@keyframes progress { from { transform: scaleX(.05); } to { transform: scaleX(.85); } }

/* ----------------------------------------------------------------------------
   Buttons, inputs, badges
   ------------------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 44px; padding: .6em 1.15em;
  border: 1.5px solid transparent; border-radius: 12px;
  font-weight: 700; font-size: 15px; line-height: 1.1; white-space: nowrap;
  background: var(--blue-50); color: var(--blue);
  transition: background-color .15s, color .15s, border-color .15s, transform .15s, box-shadow .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn .icon { width: 1.2em; height: 1.2em; }
.btn--red { background: var(--red); color: #fff; box-shadow: 0 8px 18px -8px rgba(225, 11, 11, .7); }
.btn--red:hover { background: var(--red-600); color: #fff; }
.btn--blue { background: var(--blue); color: #fff; }
.btn--blue:hover { background: var(--blue-700); color: #fff; }
.btn--wa { background: var(--wa); color: #fff; }
.btn--wa:hover { background: var(--wa-600); color: #fff; }
.btn--wa .icon { color: #fff; }
.btn--outline { background: #fff; border-color: var(--line-2); color: var(--ink); }
.btn--outline:hover { border-color: var(--blue); color: var(--blue); }
.btn--ghost { background: transparent; color: var(--muted); }
.btn--ghost:hover { color: var(--ink); background: var(--blue-50); }
.btn--danger { background: var(--red-50); color: var(--red-700); }
.btn--danger:hover { background: var(--red); color: #fff; }
.btn--sm { min-height: 36px; padding: .4em .8em; font-size: 14px; border-radius: 10px; }
.btn--lg { min-height: 50px; padding: .7em 1.4em; font-size: 16px; }
.btn--xl { min-height: 58px; padding: .8em 1.6em; font-size: 18px; border-radius: 14px; }
.btn--block { display: flex; width: 100%; }

.icon-btn {
  display: inline-grid; place-items: center; width: 44px; height: 44px; flex: none;
  border: 0; border-radius: 12px; background: transparent; color: var(--ink);
}
.icon-btn:hover { background: var(--blue-50); color: var(--blue); }
.icon-btn .icon { width: 22px; height: 22px; }

.input, .select, textarea.input {
  width: 100%; min-height: 44px; padding: 10px 12px;
  border: 1.5px solid var(--line-2); border-radius: var(--radius-sm); background: #fff;
  transition: border-color .15s, box-shadow .15s;
}
.input:focus, .select:focus { outline: 0; border-color: var(--blue); box-shadow: 0 0 0 4px rgba(10, 58, 156, .12); }
.select { appearance: none; padding-right: 36px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235b6480' stroke-width='2.2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 10px center / 18px; }

.badge {
  display: inline-flex; align-items: center; gap: .3em;
  padding: 4px 8px; border-radius: 7px;
  font: 700 12px/1.1 var(--font); letter-spacing: .02em;
  background: var(--blue-50); color: var(--blue);
}
.badge--red { background: var(--red); color: #fff; }
.badge--blue { background: var(--blue); color: #fff; }
.badge--muted { background: #e9edf4; color: var(--ink-2); }
.badge--lg { font-size: 13px; padding: 6px 10px; }

.spinner { display: none; width: 16px; height: 16px; border: 2.5px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .7s linear infinite; }
.htmx-request .spinner, .htmx-request.spinner { display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ----------------------------------------------------------------------------
   Header
   ------------------------------------------------------------------------- */
.announce { background: var(--blue-900); color: #dbe4ff; font-size: 13px; }
.announce__inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 36px; }
.announce__text, .announce__links, .announce__links > * { display: inline-flex; align-items: center; gap: 6px; }
.announce__links { gap: 18px; }
.announce a { color: #fff; font-weight: 600; }
.announce .icon { width: 16px; height: 16px; color: #ff8d8d; }

.site-header { position: sticky; top: 0; z-index: 100; background: rgba(255, 255, 255, .96); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--line); }
.header__row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: clamp(12px, 3vw, 36px); min-height: 76px; }
.brand { display: block; }
.brand img { height: 48px; width: auto; }
.header__actions { display: flex; align-items: center; gap: 6px; }

.search { position: relative; display: flex; align-items: center; max-width: 640px; width: 100%; justify-self: center; }
.search__icon { position: absolute; left: 16px; width: 20px; height: 20px; color: var(--muted); pointer-events: none; }
.search input {
  width: 100%; height: 48px; padding: 0 112px 0 46px;
  border: 1.5px solid var(--line-2); border-radius: 999px; background: var(--bg);
  transition: border-color .15s, background .15s, box-shadow .15s;
}
.search input:focus { outline: 0; border-color: var(--blue); background: #fff; box-shadow: 0 0 0 4px rgba(10, 58, 156, .12); }
.search input::-webkit-search-cancel-button { display: none; }
.search__btn { position: absolute; right: 5px; height: 38px; padding: 0 18px; border: 0; border-radius: 999px; background: var(--blue); color: #fff; font-weight: 700; }
.search__btn:hover { background: var(--blue-700); }
.search__panel { position: absolute; top: calc(100% + 8px); left: 0; right: 0; z-index: 20; }
.search__panel:empty { display: none; }

.suggest { background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow-lg); padding: 8px; max-height: min(70vh, 560px); overflow: auto; }
.suggest__cats { display: flex; flex-wrap: wrap; gap: 6px; padding: 6px 6px 10px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.suggest__cats a { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 999px; background: var(--blue-50); font-weight: 600; font-size: 14px; }
.suggest__cats .icon { width: 16px; height: 16px; }
.suggest__item { display: grid; grid-template-columns: 48px 1fr auto; align-items: center; gap: 12px; padding: 8px; border-radius: 10px; color: var(--ink); }
.suggest__item:hover, .suggest__item:focus { background: var(--bg); color: var(--ink); }
.suggest__thumb { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 8px; background: #fff; border: 1px solid var(--line); overflow: hidden; color: var(--line-2); }
.suggest__thumb img { width: 100%; height: 100%; object-fit: contain; }
.suggest__text { min-width: 0; }
.suggest__text strong { display: block; font-weight: 600; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.suggest__text small { color: var(--muted); }
.suggest__price { font: 800 17px var(--display); color: var(--blue-900); }
.suggest__empty { padding: 14px; margin: 0; color: var(--muted); }
.suggest__all { display: flex; align-items: center; justify-content: center; gap: 6px; padding: 12px; margin-top: 4px; border-top: 1px solid var(--line); font-weight: 700; }

.catnav { border-top: 1px solid var(--line); }
.catnav__track { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-block: 8px; }
.catnav__track::-webkit-scrollbar { display: none; }
.catnav__link {
  display: inline-flex; align-items: center; gap: 8px; flex: none;
  padding: 8px 14px; border-radius: 999px;
  color: var(--ink-2); font-weight: 600; font-size: 15px; white-space: nowrap;
}
.catnav__link .icon { width: 18px; height: 18px; color: var(--red); }
.catnav__link:hover { background: var(--blue-50); color: var(--blue); }
.catnav__link.is-active { background: var(--blue); color: #fff; }
.catnav__link.is-active .icon { color: #fff; }

.show-sm { display: none !important; }

@media (max-width: 860px) {
  .show-sm { display: inline-grid !important; }
  .hide-sm { display: none !important; }
  .header__row { grid-template-columns: minmax(0, 1fr) auto; min-height: 62px; gap: 8px; }
  .brand img { height: 34px; }
  .header__wa span { display: none; }
  .header__wa { width: 44px; padding: 0; }
  .search { display: none; grid-column: 1 / -1; grid-row: 2; max-width: none; margin-bottom: 10px; }
  .search-open .search { display: flex; }
  .search input { height: 46px; font-size: 16px; }
  .announce__links { display: none; }
  .announce__inner { justify-content: center; text-align: center; font-size: 12.5px; min-height: 32px; }
  .catnav__link { font-size: 14px; padding: 7px 12px; }
}

/* ----------------------------------------------------------------------------
   Hero carousel
   ------------------------------------------------------------------------- */
.hero { margin-top: 20px; }
.carousel { position: relative; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); background: var(--blue-900); }
.carousel__track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; scrollbar-width: none; overscroll-behavior-x: contain; }
.carousel__track::-webkit-scrollbar { display: none; }
.slide {
  position: relative; isolation: isolate; overflow: hidden;
  flex: 0 0 100%; scroll-snap-align: start;
  display: flex; align-items: center;
  aspect-ratio: 21 / 8; min-height: 320px;
  background: var(--blue-900); color: #fff;
}
.slide--solo { border-radius: var(--radius-lg); box-shadow: var(--shadow); }
.slide__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.slide::before { content: ""; position: absolute; inset: 0; z-index: -1; }
.slide--dark::before { background: linear-gradient(90deg, rgba(6, 26, 71, .9) 0%, rgba(6, 26, 71, .6) 42%, rgba(6, 26, 71, 0) 78%); }
.slide--dark.slide--right::before { background: linear-gradient(270deg, rgba(6, 26, 71, .9) 0%, rgba(6, 26, 71, .6) 42%, rgba(6, 26, 71, 0) 78%); }
.slide--dark.slide--center::before { background: rgba(6, 26, 71, .58); }
.slide--light { color: var(--ink); }
.slide--light::before { background: linear-gradient(90deg, rgba(255, 255, 255, .94) 0%, rgba(255, 255, 255, .7) 42%, rgba(255, 255, 255, 0) 78%); }
.slide--light.slide--right::before { background: linear-gradient(270deg, rgba(255, 255, 255, .94) 0%, rgba(255, 255, 255, .7) 42%, rgba(255, 255, 255, 0) 78%); }
.slide--light.slide--center::before { background: rgba(255, 255, 255, .7); }
.slide--none::before { display: none; }
.slide--center { justify-content: center; text-align: center; }
.slide--right { justify-content: flex-end; }
.slide__content { position: relative; max-width: min(640px, 100%); padding: clamp(28px, 5vw, 72px); }
.slide--center .slide__sub { margin-inline: auto; }
.slide__eyebrow {
  display: inline-block; margin-bottom: 14px; padding: 6px 11px; border-radius: 7px;
  background: var(--red); color: #fff; font: 700 12px/1 var(--font); letter-spacing: .16em; text-transform: uppercase;
}
.slide__title { font: 800 clamp(34px, 5.4vw, 68px)/.96 var(--display); text-transform: uppercase; letter-spacing: .005em; margin-bottom: 14px; text-wrap: balance; }
.slide__sub { font-size: clamp(15px, 1.5vw, 19px); opacity: .92; margin-bottom: 24px; max-width: 46ch; }

/* banner without an image: brand gradient + the logo mark */
.slide--ph {
  background:
    radial-gradient(70% 90% at 85% 50%, rgba(11, 70, 187, .85), transparent 70%),
    repeating-linear-gradient(-45deg, rgba(255, 255, 255, .035) 0 2px, transparent 2px 18px),
    linear-gradient(120deg, var(--blue-900), var(--blue-800) 55%, var(--blue));
}
.slide--ph::before { display: none; }
.slide--ph.slide--light { background: radial-gradient(70% 90% at 85% 50%, #fff, var(--blue-50) 70%); }
.slide__mark { position: absolute; right: 4%; top: 50%; transform: translateY(-50%) rotate(-4deg); width: min(44%, 520px); height: auto; z-index: -1; filter: drop-shadow(0 24px 30px rgba(0, 0, 0, .35)); }
.slide--right .slide__mark { right: auto; left: 4%; }
.slide--center .slide__mark { opacity: .18; right: 50%; transform: translate(50%, -50%); }

.carousel__arrow {
  position: absolute; top: 50%; translate: 0 -50%; z-index: 2;
  display: grid; place-items: center; width: 46px; height: 46px;
  border: 0; border-radius: 50%; background: rgba(255, 255, 255, .92); color: var(--blue-900);
  box-shadow: var(--shadow); opacity: 0; transition: opacity .2s, background .2s;
}
.carousel:hover .carousel__arrow, .carousel__arrow:focus-visible { opacity: 1; }
.carousel__arrow:hover { background: #fff; color: var(--red); }
.carousel__arrow--prev { left: 16px; }
.carousel__arrow--next { right: 16px; }
.carousel__dots { position: absolute; left: 0; right: 0; bottom: 16px; z-index: 2; display: flex; justify-content: center; gap: 8px; }
.carousel__dots button { width: 10px; height: 10px; padding: 0; border: 0; border-radius: 10px; background: rgba(255, 255, 255, .5); transition: width .3s, background .3s; }
.carousel__dots button.is-active { width: 30px; background: var(--red); }

@media (max-width: 700px) {
  .hero { margin-top: 12px; }
  .slide { aspect-ratio: auto; min-height: 420px; align-items: flex-end; }
  .slide--dark::before, .slide--dark.slide--right::before { background: linear-gradient(0deg, rgba(6, 26, 71, .95) 0%, rgba(6, 26, 71, .6) 50%, rgba(6, 26, 71, .05) 100%); }
  .slide--light::before, .slide--light.slide--right::before { background: linear-gradient(0deg, rgba(255, 255, 255, .96) 0%, rgba(255, 255, 255, .7) 50%, rgba(255, 255, 255, 0) 100%); }
  .slide--right { justify-content: flex-start; }
  .slide__content { padding: 24px 22px 48px; }
  .slide__mark, .slide--right .slide__mark { width: 58%; left: auto; right: 6%; top: 6%; transform: rotate(-4deg); }
  .slide--center .slide__mark { right: 11%; transform: none; }
  .carousel__arrow { display: none; }
}

/* ----------------------------------------------------------------------------
   Sections, categories
   ------------------------------------------------------------------------- */
.section { padding-block: clamp(28px, 4vw, 52px); }
.section + .section { padding-top: 0; }
.section__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.section__title {
  display: flex; align-items: center; gap: 10px;
  font: 800 clamp(24px, 3vw, 34px)/1 var(--display); text-transform: uppercase; color: var(--blue-900); letter-spacing: .01em;
}
.section__title::before { content: ""; width: 6px; height: .95em; border-radius: 3px; background: var(--red); flex: none; }
.section__title .icon { color: var(--red); width: .9em; height: .9em; }
.section__icon { display: inline-grid; place-items: center; }
.link-more { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; white-space: nowrap; }
.link-more .icon { width: 18px; height: 18px; transition: transform .2s; }
.link-more:hover .icon { transform: translateX(3px); }

.section--deals { background: linear-gradient(180deg, var(--red-50), rgba(255, 241, 241, 0)); padding-top: clamp(28px, 4vw, 48px) !important; }
.section--deals .section__title { color: var(--red-700); }

.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
.cat-tile {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center;
  padding: 20px 12px 16px; border: 1px solid var(--line); border-radius: var(--radius);
  background: #fff; color: var(--ink); overflow: hidden;
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.cat-tile:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--blue-100); color: var(--ink); }
.cat-tile__icon { display: grid; place-items: center; width: 60px; height: 60px; margin-bottom: 8px; border-radius: 18px; background: var(--red-50); color: var(--red); transition: background .2s, color .2s; }
.cat-tile__icon .icon { width: 30px; height: 30px; }
.cat-tile:hover .cat-tile__icon { background: var(--red); color: #fff; }
.cat-tile strong { font: 700 18px/1.1 var(--display); text-transform: uppercase; letter-spacing: .02em; }
.cat-tile__count { font-size: 13px; color: var(--muted); }
.cat-tile--img { padding-top: 0; }
.cat-tile--img img { width: calc(100% + 24px); max-width: none; margin: 0 -12px 12px; aspect-ratio: 4 / 3; object-fit: cover; }
.cat-tile--img .cat-tile__icon { display: none; }
.cat-tile--img.is-broken img { display: none; }
.cat-tile--img.is-broken .cat-tile__icon { display: grid; margin-top: 20px; }

@media (max-width: 560px) {
  .cat-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .cat-tile { padding: 14px 6px 12px; }
  .cat-tile__icon { width: 48px; height: 48px; border-radius: 14px; margin-bottom: 4px; }
  .cat-tile__icon .icon { width: 24px; height: 24px; }
  .cat-tile strong { font-size: 15px; }
  .cat-tile__count { font-size: 12px; }
}

/* ----------------------------------------------------------------------------
   Product cards, grids, shelves
   ------------------------------------------------------------------------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 18px; }

.card {
  container: card / inline-size;
  position: relative; display: flex; flex-direction: column; min-width: 0;
  background: #fff; border: 1px solid var(--line); border-radius: 18px; overflow: hidden;
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--blue-100); }
.card__media { position: relative; display: block; aspect-ratio: 1; background: #fff; border-bottom: 1px solid var(--line); }
.card__media img { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; padding: 14px; object-fit: contain; background: #fff; transition: transform .35s; }
.card:hover .card__media img { transform: scale(1.04); }
.card__ph, .gallery__ph { position: absolute; inset: 0; display: grid; place-items: center; color: var(--blue-100); background: radial-gradient(circle at 50% 45%, #fff, var(--blue-50)); }
.card__ph .icon { width: 42%; height: 42%; stroke-width: 1.2; }
.is-broken img { display: none !important; }
.card__badges { position: absolute; top: 10px; left: 10px; z-index: 2; display: flex; flex-wrap: wrap; gap: 5px; }
.card__body { display: flex; flex-direction: column; gap: 4px; flex: 1; padding: 14px 14px 16px; }
.card__brand { font: 700 11.5px/1.2 var(--font); text-transform: uppercase; letter-spacing: .12em; color: var(--blue); }
.card__title { font-size: 15.5px; font-weight: 600; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card__title a { color: var(--ink); }
.card__title a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.card__tagline { margin: 0; font-size: 13.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 8px; margin: 6px 0 12px; }
.price strong { font: 800 23px/1 var(--display); color: var(--blue-900); letter-spacing: .01em; }
.price s { font-size: 14px; color: var(--muted); }
.card__wa { position: relative; z-index: 2; margin-top: auto; min-height: 42px; font-size: 14.5px; }
.wa-short { display: none; }
.card--out .card__media img { opacity: .55; filter: grayscale(.6); }

@container card (max-width: 210px) {
  .card__body { padding: 10px 10px 12px; }
  .card__title { font-size: 14px; }
  .price strong { font-size: 19px; }
  .price s { font-size: 12.5px; }
  .card__wa { font-size: 14px; min-height: 40px; padding-inline: 8px; }
  .wa-long { display: none; }
  .wa-short { display: inline; }
  .card__tagline { display: none; }
}

@media (max-width: 560px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .card { border-radius: 14px; }
  .card__media img { padding: 10px; }
}

.shelf { position: relative; }
.shelf__track {
  display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 3 * 18px) / 4);
  gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth;
  padding: 4px 2px 10px; margin: -4px -2px 0; scrollbar-width: none;
}
.shelf__track::-webkit-scrollbar { display: none; }
.shelf__track > * { scroll-snap-align: start; }
.shelf__nav {
  position: absolute; top: 36%; z-index: 3; display: grid; place-items: center;
  width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 50%;
  background: #fff; color: var(--ink); box-shadow: var(--shadow); transition: opacity .2s;
}
.shelf__nav:hover { color: var(--red); }
.shelf__nav[disabled] { opacity: 0; pointer-events: none; }
.shelf__nav--prev { left: -18px; }
.shelf__nav--next { right: -18px; }
@media (max-width: 1100px) { .shelf__track { grid-auto-columns: calc((100% - 2 * 18px) / 3); } }
@media (max-width: 760px) {
  .shelf__track { grid-auto-columns: 46%; gap: 10px; margin-inline: calc(var(--gutter) * -1); padding-inline: var(--gutter); scroll-padding-inline: var(--gutter); }
  .shelf__nav { display: none; }
}

.cta-band {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 20px;
  padding: clamp(24px, 4vw, 40px); border-radius: var(--radius-lg); color: #fff;
  background:
    radial-gradient(60% 120% at 100% 0%, rgba(225, 11, 11, .55), transparent 60%),
    linear-gradient(120deg, var(--blue-900), var(--blue));
}
.cta-band h2 { font: 800 clamp(26px, 3.2vw, 38px)/1 var(--display); text-transform: uppercase; margin-bottom: 8px; }
.cta-band p { margin: 0; opacity: .9; max-width: 56ch; }

.empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; padding: clamp(32px, 6vw, 64px) 20px; background: #fff; border: 1px dashed var(--line-2); border-radius: var(--radius-lg); }
.empty h1, .empty h2 { font: 800 clamp(26px, 3vw, 34px)/1.05 var(--display); text-transform: uppercase; color: var(--blue-900); }
.empty p { color: var(--muted); max-width: 46ch; margin: 0 0 6px; }
.empty img { width: 160px; height: auto; margin-bottom: 6px; }
.empty__icon { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: var(--blue-50); color: var(--blue); }
.empty__icon .icon { width: 28px; height: 28px; }
.empty__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.empty--compact { grid-column: 1 / -1; }

/* ----------------------------------------------------------------------------
   Shop page + filters
   ------------------------------------------------------------------------- */
.page-head { padding-block: 22px 18px; }
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 14px; color: var(--muted); margin-bottom: 10px; }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--blue); }
.crumbs [aria-current] { color: var(--ink-2); font-weight: 600; }
.page-title { display: flex; align-items: center; gap: 12px; font: 800 clamp(30px, 4vw, 46px)/1 var(--display); text-transform: uppercase; color: var(--blue-900); }
.page-title .icon { color: var(--red); }
.page-title__icon { display: grid; place-items: center; width: 1.25em; height: 1.25em; border-radius: 12px; background: var(--red-50); }
.page-title__icon .icon { width: .75em; height: .75em; }
.lead { color: var(--muted); font-size: 17px; margin: 10px 0 0; max-width: 60ch; }

.shop { padding-bottom: 48px; }
.shop__layout { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 28px; align-items: start; }
.filters { position: sticky; top: calc(var(--header-h) + 16px); max-height: calc(100vh - var(--header-h) - 32px); overflow: auto; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); scrollbar-width: thin; }
.filters__head { display: none; }
.filters__body { padding: 6px 18px 18px; }
.filters__foot { display: none; }
.fgroup { margin: 0; padding: 16px 0; border: 0; border-bottom: 1px solid var(--line); min-width: 0; }
.fgroup:last-child { border-bottom: 0; }
.fgroup__label { display: block; padding: 0; margin-bottom: 10px; font: 700 13px/1 var(--font); text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.field-icon { position: relative; }
.field-icon .icon { position: absolute; left: 12px; top: 50%; translate: 0 -50%; width: 18px; height: 18px; color: var(--muted); }
.field-icon .input { padding-left: 38px; }
.fcats { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.fcats a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px; color: var(--ink-2); font-weight: 500; }
.fcats a:hover { background: var(--bg); color: var(--ink); }
.fcats a.is-active { background: var(--blue-50); color: var(--blue); font-weight: 700; }
.fcats .icon { width: 18px; height: 18px; color: var(--red); }
.fcats span { flex: 1; }
.fcats small { color: var(--muted); font-size: 13px; }
.checks { display: grid; gap: 4px; }
.checks--scroll { max-height: 260px; overflow: auto; }
.check { display: flex; align-items: center; gap: 10px; padding: 6px 4px; border-radius: 8px; cursor: pointer; }
.check:hover { background: var(--bg); }
.check input { width: 18px; height: 18px; accent-color: var(--blue); margin: 0; }
.price-range { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px; }
.price-range .input { min-width: 0; }
.switch { display: flex; align-items: center; gap: 12px; padding: 6px 0; cursor: pointer; font-weight: 500; }
.switch input { position: absolute; opacity: 0; }
.switch__ui { position: relative; width: 40px; height: 24px; border-radius: 24px; background: var(--line-2); transition: background .2s; flex: none; }
.switch__ui::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: var(--shadow-sm); transition: transform .2s; }
.switch input:checked + .switch__ui { background: var(--blue); }
.switch input:checked + .switch__ui::after { transform: translateX(16px); }
.switch input:focus-visible + .switch__ui { outline: 3px solid rgba(10, 58, 156, .4); outline-offset: 2px; }

.toolbar { display: flex; align-items: center; justify-content: flex-end; gap: 12px; margin-bottom: 14px; }
.toolbar__filters { display: none; margin-right: auto; }
.count-pill { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 22px; background: var(--red); color: #fff; font-size: 12px; }
.sort { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 14px; font-weight: 600; }
.sort .select { width: auto; min-width: 190px; color: var(--ink); font-weight: 600; }
.results { transition: opacity .2s; }
.results.htmx-request { opacity: .45; pointer-events: none; }
.results__meta { color: var(--muted); margin-bottom: 14px; }
.results__meta strong { color: var(--ink); }
.load-more { grid-column: 1 / -1; display: flex; justify-content: center; padding-top: 12px; }
.load-more__count { color: var(--muted); font-weight: 500; }
.load-more .htmx-request .load-more__count { display: none; }

.drawer-backdrop { position: fixed; inset: 0; z-index: 190; background: rgba(6, 26, 71, .45); backdrop-filter: blur(2px); }

@media (max-width: 960px) {
  .shop__layout { grid-template-columns: minmax(0, 1fr); }
  .toolbar__filters { display: inline-flex; }
  .sort > span { display: none; }
  .sort .select { min-width: 0; }
  .filters {
    position: fixed; inset: 0 auto 0 0; z-index: 200; top: 0;
    width: min(88vw, 380px); max-height: none; border-radius: 0 20px 20px 0; border: 0;
    display: flex; flex-direction: column;
    transform: translateX(-102%); transition: transform .3s cubic-bezier(.2, .8, .2, 1); box-shadow: var(--shadow-lg);
  }
  .filters.is-open { transform: none; }
  .filters__head { display: flex; align-items: center; justify-content: space-between; padding: 14px 12px 14px 20px; border-bottom: 1px solid var(--line); }
  .filters__head h2 { font: 800 24px/1 var(--display); text-transform: uppercase; color: var(--blue-900); }
  .filters__body { flex: 1; overflow: auto; }
  .filters__foot { display: grid; grid-template-columns: 1fr 1.4fr; gap: 10px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); }
}

/* ----------------------------------------------------------------------------
   Product page
   ------------------------------------------------------------------------- */
.pdp { padding-top: 18px; padding-bottom: 32px; }
.pdp__grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); align-items: start; }
.notice { padding: 12px 16px; margin-bottom: 16px; border-radius: 12px; background: var(--warn-bg); color: var(--warn); }

.gallery { position: sticky; top: calc(var(--header-h) + 16px); }
.gallery__main { position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; }
.gallery__track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; scrollbar-width: none; }
.gallery__track::-webkit-scrollbar { display: none; }
.gallery__slide { flex: 0 0 100%; aspect-ratio: 1; scroll-snap-align: start; display: grid; place-items: center; padding: clamp(16px, 4vw, 40px); }
.gallery__slide img { width: 100%; height: 100%; object-fit: contain; }
.gallery__ph { position: relative; aspect-ratio: 1; }
.gallery__ph .icon { width: 40%; height: 40%; stroke-width: 1.1; }
.gallery__thumbs { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.gallery__thumbs button { flex: none; width: 68px; height: 68px; padding: 6px; border: 2px solid var(--line); border-radius: 12px; background: #fff; transition: border-color .2s; }
.gallery__thumbs button.is-active { border-color: var(--red); }
.gallery__thumbs img { width: 100%; height: 100%; object-fit: contain; }

.pdp__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 10px; }
.pdp__cat { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; background: var(--red-50); color: var(--red-700); font-weight: 700; font-size: 14px; }
.pdp__cat .icon { width: 17px; height: 17px; }
.pdp__brand { font: 700 13px var(--font); text-transform: uppercase; letter-spacing: .14em; color: var(--blue); }
.pdp__title { font: 700 clamp(28px, 3.4vw, 42px)/1.05 var(--display); color: var(--ink); text-wrap: balance; }
.pdp__tagline { margin: 10px 0 0; font-size: 17px; color: var(--muted); }
.pdp__price { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin: 20px 0 16px; padding: 16px 18px; border-radius: var(--radius); background: var(--blue-50); }
.pdp__price strong { font: 800 clamp(34px, 4vw, 44px)/1 var(--display); color: var(--blue-900); }
.pdp__price s { color: var(--muted); font-size: 18px; }
.pdp__chips { list-style: none; margin: 0 0 20px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 999px; background: #fff; border: 1px solid var(--line); font-weight: 600; font-size: 14px; color: var(--ink-2); }
.chip .icon { width: 16px; height: 16px; color: var(--blue); }
.chip--ok { background: #e9f8ef; border-color: #c6ecd4; color: #0d6a30; }
.chip--ok .icon { color: #0d6a30; }
.chip--no { background: var(--red-50); border-color: var(--red-100); color: var(--red-700); }
.chip--no .icon { color: var(--red-700); }
.pdp__actions { display: grid; gap: 10px; }
.pdp__secondary { display: flex; gap: 10px; }
.pdp__secondary .btn { flex: 1; }
.pdp__note { display: flex; gap: 10px; margin: 14px 0 0; font-size: 14px; color: var(--muted); }
.pdp__note .icon { color: var(--wa); margin-top: 1px; }
.pdp__perks { list-style: none; margin: 22px 0 0; padding: 0; display: grid; gap: 2px; border-top: 1px solid var(--line); }
.pdp__perks li { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; color: var(--muted); }
.pdp__perks strong { display: block; color: var(--ink); font-size: 15px; }
.pdp__perks .icon { width: 22px; height: 22px; color: var(--red); margin-top: 2px; }
.staff-edit { display: inline-flex; align-items: center; gap: 6px; margin-top: 16px; font-weight: 700; }
.staff-edit .icon { width: 18px; height: 18px; }

.pdp__details { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 20px; margin-top: clamp(28px, 4vw, 48px); }
.pdp__details .panel:only-child { grid-column: 1 / -1; }
.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(18px, 3vw, 28px); }
.panel__title { font: 800 24px/1 var(--display); text-transform: uppercase; color: var(--blue-900); margin-bottom: 14px; }
.prose { color: var(--ink-2); font-size: 16.5px; line-height: 1.65; }
.prose p:last-child { margin-bottom: 0; }
.specs { width: 100%; border-collapse: collapse; font-size: 15px; }
.specs th, .specs td { padding: 11px 12px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.specs th { width: 42%; color: var(--muted); font-weight: 600; }
.specs tr:nth-child(odd) { background: var(--bg); }
.specs tr:last-child th, .specs tr:last-child td { border-bottom: 0; }

.buybar { display: none; }

@media (max-width: 860px) {
  .pdp__grid { grid-template-columns: minmax(0, 1fr); }
  .gallery { position: static; margin-inline: calc(var(--gutter) * -1); }
  .gallery__main { border-radius: 0; border-inline: 0; }
  .pdp__details { grid-template-columns: minmax(0, 1fr); }
  .pdp__actions .btn--wa { display: none; }
  .buybar {
    position: fixed; inset: auto 0 0; z-index: 150;
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    padding: 10px var(--gutter) calc(10px + env(safe-area-inset-bottom));
    background: rgba(255, 255, 255, .97); backdrop-filter: blur(8px);
    border-top: 1px solid var(--line); box-shadow: 0 -8px 24px -12px rgba(13, 22, 48, .2);
  }
  .buybar__price strong { display: block; font: 800 24px/1 var(--display); color: var(--blue-900); }
  .buybar__price s { font-size: 13px; color: var(--muted); }
  .buybar .btn { flex: 1; max-width: 240px; }
  body.has-buybar { --bottom-nav-h: calc(72px + env(safe-area-inset-bottom)); }
}

/* ----------------------------------------------------------------------------
   Footer, trust strip, bottom nav, toasts
   ------------------------------------------------------------------------- */
.trust { background: #fff; border-top: 1px solid var(--line); margin-top: clamp(24px, 4vw, 48px); }
.trust__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; padding-block: 26px; }
.trust__item { display: flex; gap: 14px; align-items: flex-start; }
.trust__item > .icon { width: 44px; height: 44px; padding: 10px; border-radius: 14px; background: var(--red-50); color: var(--red); }
.trust__item strong { display: block; font-size: 15.5px; }
.trust__item span { font-size: 14px; color: var(--muted); }
@media (max-width: 900px) { .trust__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .trust__grid { grid-template-columns: minmax(0, 1fr); gap: 14px; } }

.footer { background: var(--blue-900); color: #b9c6e6; font-size: 15px; }
.footer a { color: #fff; }
.footer a:hover { color: #ffb4b4; }
.footer__grid { display: grid; grid-template-columns: 1.3fr 1fr 1.1fr 1.3fr; gap: 32px; padding-block: 44px 32px; }
.footer__logo { display: inline-flex; flex-direction: column; gap: 4px; }
.footer__logo img { width: 130px; height: auto; }
.wordmark { font: 800 30px/1 var(--display); color: #fff; letter-spacing: .01em; }
.wordmark em { font-style: normal; color: #ff3b3b; font-size: .75em; }
.footer__tag { margin: 6px 0 16px; text-transform: uppercase; letter-spacing: .18em; font-size: 12px; font-weight: 700; color: #8fa3d6; }
.footer__social { display: flex; gap: 8px; }
.footer__social a { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: rgba(255, 255, 255, .08); }
.footer__social a:hover { background: var(--red); color: #fff; }
.footer__social .icon { width: 20px; height: 20px; }
.footer__h { font: 800 18px/1 var(--display); text-transform: uppercase; letter-spacing: .06em; color: #fff; margin-bottom: 14px; }
.footer__list { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; }
.footer__contact li { display: flex; gap: 10px; align-items: flex-start; }
.footer__contact .icon { width: 18px; height: 18px; color: #ff8d8d; margin-top: 2px; }
.footer__cta p { margin-bottom: 16px; }
.footer__base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; padding-block: 18px; border-top: 1px solid rgba(255, 255, 255, .1); font-size: 13px; color: #8396c4; }
.footer__credit { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px 14px; padding-block: 14px 18px; border-top: 1px solid rgba(255, 255, 255, .06); font-size: 13px; color: #8396c4; text-align: center; }
.footer__credit strong { color: #fff; font-weight: 700; }
.footer__credit a { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; }
.footer__credit .icon { width: 16px; height: 16px; color: #25d366; }
@media (max-width: 900px) { .footer__grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer__grid { grid-template-columns: minmax(0, 1fr); gap: 26px; } }

.bottom-nav { display: none; }
@media (max-width: 860px) {
  body { --bottom-nav-h: calc(64px + env(safe-area-inset-bottom)); }
  .bottom-nav {
    position: fixed; inset: auto 0 0; z-index: 150;
    display: grid; grid-template-columns: repeat(5, 1fr);
    padding-bottom: env(safe-area-inset-bottom);
    background: rgba(255, 255, 255, .97); backdrop-filter: blur(8px);
    border-top: 1px solid var(--line);
  }
  .bottom-nav > * {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
    height: 64px; border: 0; background: none; color: var(--muted); font-size: 11.5px; font-weight: 600;
  }
  .bottom-nav .icon { width: 23px; height: 23px; }
  .bottom-nav .is-active { color: var(--blue); }
  .bottom-nav__wa { color: var(--wa) !important; }
  .bottom-nav__wa .icon { color: var(--wa-bright); filter: drop-shadow(0 2px 4px rgba(19, 133, 60, .3)); }
}

.toasts { position: fixed; right: 16px; bottom: calc(16px + var(--bottom-nav-h)); z-index: 2600; display: grid; gap: 8px; max-width: min(420px, calc(100vw - 32px)); }
.toast {
  padding: 13px 16px; border-radius: 12px; background: var(--ink); color: #fff; box-shadow: var(--shadow-lg);
  font-weight: 600; font-size: 15px; animation: toast-in .3s cubic-bezier(.2, .9, .3, 1.2);
  border-left: 5px solid var(--blue-600);
}
.toast--success { border-left-color: var(--wa-bright); }
.toast--error { border-left-color: var(--red); }
.toast--warning { border-left-color: #f5b400; }
.toast.is-leaving { opacity: 0; transform: translateY(8px); transition: opacity .3s, transform .3s; }
@keyframes toast-in { from { opacity: 0; transform: translateY(12px) scale(.96); } }

/* ----------------------------------------------------------------------------
   Error pages (403, 404 — the 400/500 pages are self-contained)
   ------------------------------------------------------------------------- */
.err { display: flex; flex-direction: column; align-items: center; text-align: center; padding-block: clamp(32px, 6vw, 72px); }
.err__art { width: min(340px, 80vw); margin-bottom: 4px; }
.err__mark { width: 100%; height: auto; overflow: visible; }
.err__code { margin: 0; font: 700 13px/1 var(--font); letter-spacing: .2em; text-transform: uppercase; color: var(--red); }
.err__title { margin: 10px 0; font: 800 clamp(32px, 5vw, 52px)/1 var(--display); text-transform: uppercase; color: var(--blue-900); text-wrap: balance; }
.err__text { max-width: 48ch; margin: 0 0 24px; color: var(--muted); font-size: 17px; }
.err__search { position: relative; display: flex; gap: 8px; width: min(520px, 100%); margin-bottom: 18px; }
.err__search-icon { position: absolute; left: 14px; top: 50%; translate: 0 -50%; width: 20px; height: 20px; color: var(--muted); }
.err__search input { flex: 1; min-width: 0; height: 50px; padding: 0 14px 0 44px; border: 1.5px solid var(--line-2); border-radius: 12px; background: #fff; font-size: 16px; }
.err__search input:focus { outline: 0; border-color: var(--blue); box-shadow: 0 0 0 4px rgba(10, 58, 156, .12); }
.err__search .btn { min-height: 50px; }
.err__cats { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 26px; max-width: 640px; }
.err__cats a { display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px; background: #fff; color: var(--ink-2); font-weight: 600; }
.err__cats a:hover { border-color: var(--blue); color: var(--blue); }
.err__cats .icon { width: 17px; height: 17px; color: var(--red); }
.err__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }

/* 404: the cart rolls off and comes back, cable left dangling */
.err--404 .ld-ripple, .err--404 .ld-speed { display: none; }
.err--404 .ld-cart { animation: err-roll 4.2s cubic-bezier(.55, 0, .35, 1) infinite; }
@keyframes err-roll {
  0%, 18% { transform: translateX(0); opacity: 1; }
  48% { transform: translateX(170px); opacity: 0; }
  49% { transform: translateX(0) translateY(-14px); opacity: 0; }
  62% { transform: translateY(0); opacity: 1; }
  68% { transform: translateY(-4px); }
  74%, 100% { transform: translateY(0); }
}
/* 403: unplugged */
.err--403 .ld-ripple, .err--403 .ld-speed { display: none; }
.err--403 .ld-cable { animation: none; stroke-dasharray: 5 6; stroke-dashoffset: 0; opacity: .45; }
.err--403 .ld-cart, .err--403 .ld-wheel, .err--403 .ld-mouse { animation: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
  .err .ld-cart { animation: none; }
}
