/* SmartBiz shop kit: the base every kit design builds on.
   A design sets the tokens below on its body class and styles its own home
   sections. Everything here serves the shared engine pages: catalogue,
   product, basket, checkout, about, contact, policies and 404. */

:root {
  --ground: #ffffff;
  --surface: #f3f3ef;
  --surface-2: #e9e8e2;
  --ink: #17160f;
  --ink-soft: #57544a;
  --line: #dddbd2;
  --radius: 14px;
  --radius-sm: 8px;
  --radius-btn: 999px;
  --font-display: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --wrap: 1200px;
  --gutter: clamp(16px, 4vw, 40px);
  --space-section: clamp(56px, 8vw, 112px);
  --header-h: 68px;
  --shadow: 0 1px 2px rgba(23, 22, 15, .06), 0 10px 30px rgba(23, 22, 15, .08);
  --primary: #1d6b43;
  --secondary: #f4b000;
  --tint: #f4b000;
  --on-primary: #ffffff;
  --on-secondary: #15140f;
  --primary-text: #1d6b43;
  --secondary-text: #7a5800;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  padding-bottom: 60px;
  overflow-x: hidden;
}
@media (min-width: 900px) { body { padding-bottom: 0; } }
body.is-menu-open { overflow: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.08; margin: 0 0 .5em; text-wrap: balance; }
h1 { font-size: clamp(2.2rem, 1.5rem + 3.2vw, 4.2rem); letter-spacing: -.02em; }
h2 { font-size: clamp(1.75rem, 1.3rem + 1.9vw, 2.9rem); letter-spacing: -.015em; }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
figure { margin: 0; }
button, input, select, textarea { font: inherit; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }

.wrap { width: min(calc(100% - 2 * var(--gutter)), var(--wrap)); margin-inline: auto; }
.section { padding-block: var(--space-section); }
.eyebrow {
  margin: 0 0 .8rem;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--primary-text);
}
.lead { font-size: clamp(1.02rem, .95rem + .35vw, 1.2rem); color: var(--ink-soft); max-width: 62ch; }
.muted, .is-muted { color: var(--ink-soft); }

.skip-link {
  position: absolute; left: 12px; top: 12px; z-index: 100;
  padding: 10px 14px; border-radius: 8px;
  background: var(--ink); color: var(--ground); font-weight: 700; text-decoration: none;
  transform: translateY(-220%);
}
.skip-link:focus { transform: none; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 50px; padding: .8em 1.5em;
  border: 2px solid var(--ink); border-radius: var(--radius-btn);
  background: transparent; color: var(--ink);
  font: 700 1rem/1.1 var(--font-body); text-decoration: none; text-align: center;
  cursor: pointer; transition: transform .15s ease, filter .15s ease, background-color .15s ease;
}
.btn:hover { filter: brightness(1.05); }
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.btn--light { background: #ffffff; border-color: #ffffff; color: #17160f; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 40; background: var(--ground); border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: var(--header-h); }
.brand { display: inline-flex; align-items: center; min-width: 0; text-decoration: none; }
.merchant-logo { width: auto; max-width: 180px; max-height: 48px; object-fit: contain; }
.brand-word { display: flex; flex-direction: column; min-width: 0; line-height: 1.1; }
.brand-word strong {
  font-family: var(--font-display); font-size: 1.2rem; font-weight: 800;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 52vw;
}
.brand-word small { font-size: .74rem; color: var(--ink-soft); letter-spacing: .03em; }
.desktop-nav { display: none; align-items: center; gap: 28px; }
.desktop-nav a { padding: 6px 0; font-weight: 600; text-decoration: none; border-bottom: 2px solid transparent; }
.desktop-nav a:hover, .desktop-nav a[aria-current="page"] { border-color: currentColor; }
.header-actions { display: flex; align-items: center; gap: 10px; }
.basket-link {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 8px 0 16px;
  border-radius: 999px; background: var(--ink); color: var(--ground); font-weight: 700; text-decoration: none;
}
.basket-count {
  display: inline-grid; place-items: center; min-width: 26px; height: 26px; padding: 0 7px;
  border-radius: 999px; background: var(--secondary); color: var(--on-secondary);
  font-size: .8rem; font-weight: 800; font-variant-numeric: tabular-nums;
}
.menu-button {
  display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
  width: 44px; height: 44px; padding: 0 11px;
  border: 1.5px solid var(--line); border-radius: 10px; background: var(--ground); cursor: pointer;
}
/* Some browsers start button contents at the left edge instead of stretching them. */
.menu-button span { display: block; width: 100%; height: 2px; border-radius: 2px; background: var(--ink); }
.mobile-menu {
  position: fixed; left: 0; right: 0; top: var(--header-h); z-index: 39;
  display: grid; gap: 2px; padding: 10px var(--gutter) 22px;
  background: var(--ground); border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
}
.mobile-menu[hidden] { display: none; }
.mobile-menu a { padding: 14px 4px; font-size: 1.1rem; font-weight: 700; text-decoration: none; border-bottom: 1px solid var(--line); }
@media (min-width: 900px) {
  .desktop-nav { display: flex; }
  .menu-button { display: none; }
}

/* Phone bottom bar */
.bottom-nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 38;
  display: grid; grid-template-columns: repeat(4, 1fr);
  padding-bottom: env(safe-area-inset-bottom);
  background: var(--ground); border-top: 1px solid var(--line);
}
.bottom-nav a {
  display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 58px;
  font-size: .82rem; font-weight: 700; text-decoration: none;
}
.bottom-nav .basket-count { min-width: 22px; height: 22px; font-size: .72rem; }
@media (min-width: 900px) { .bottom-nav { display: none; } }

/* Footer */
.site-footer { padding-block: 56px 28px; background: var(--ink); color: #f4f2ec; }
.footer-grid { display: grid; gap: 28px; grid-template-columns: 1fr; }
@media (min-width: 760px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1.2fr; } }
.site-footer h2 { font-size: 1.5rem; margin-bottom: .4em; }
.site-footer h3 { margin: 0 0 .7em; font-family: var(--font-body); font-size: .76rem; letter-spacing: .12em; text-transform: uppercase; opacity: .7; }
.site-footer a, .site-footer span { display: block; padding: 4px 0; color: inherit; text-decoration: none; overflow-wrap: anywhere; }
.site-footer a:hover { text-decoration: underline; }
.site-footer p { opacity: .8; max-width: 40ch; }
.footer-bottom {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px;
  margin-top: 40px; padding-top: 18px; border-top: 1px solid rgba(255, 255, 255, .16);
  font-size: .85rem; opacity: .75;
}

/* Engine pages */
.page-hero { padding-block: clamp(36px, 6vw, 72px) clamp(22px, 3vw, 34px); background: var(--surface); }
.page-hero h1 { font-size: clamp(2rem, 1.4rem + 2.6vw, 3.4rem); margin-bottom: .3em; }
.page-hero .lead { margin: 0; }
.breadcrumb { margin: 0 0 .6rem; font-size: .88rem; color: var(--ink-soft); }
.breadcrumb a { text-decoration: none; border-bottom: 1px solid currentColor; }

.section--catalogue { padding-top: 32px; }
.catalog-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 24px; }
.filter-row { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  min-height: 42px; padding: 0 16px; border-radius: 999px;
  border: 1.5px solid var(--line); background: var(--ground); color: var(--ink);
  font-size: .92rem; font-weight: 600; cursor: pointer;
}
.chip.is-active { background: var(--ink); border-color: var(--ink); color: var(--ground); }
.sort {
  min-height: 44px; padding: 0 14px; border-radius: 10px;
  border: 1.5px solid var(--line); background: var(--ground); color: var(--ink); font-weight: 600;
}

.product-grid { display: grid; gap: clamp(12px, 2vw, 24px); grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 760px) { .product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .product-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.product-grid > .empty-state { grid-column: 1 / -1; }

.product-card {
  position: relative; display: flex; flex-direction: column; min-width: 0;
  background: var(--ground); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
}
.product-card[hidden] { display: none; }
.product-art { display: block; aspect-ratio: 1 / 1; overflow: hidden; background: var(--surface); }
.product-art img { width: 100%; height: 100%; aspect-ratio: 1 / 1; object-fit: cover; transition: transform .45s ease; }
.product-card:hover .product-art img { transform: scale(1.04); }
.product-media {
  display: grid; place-items: center; width: 100%; height: 100%; min-height: 100px;
  background: linear-gradient(135deg, var(--surface), var(--surface-2));
}
.product-media span {
  font-family: var(--font-display); font-size: clamp(2.4rem, 1.6rem + 3vw, 4rem); font-weight: 800;
  line-height: 1; color: var(--ink); opacity: .2;
}
.product-info { display: flex; flex: 1; flex-direction: column; gap: 4px; padding: 12px 14px 14px; }
.product-category { margin: 0; font-size: .72rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); }
.product-info h3 { margin: 0; font-family: var(--font-body); font-size: 1.02rem; font-weight: 700; line-height: 1.25; }
.product-info h3 a { display: block; padding-block: 4px; text-decoration: none; }
.product-description {
  margin: 0; font-size: .88rem; color: var(--ink-soft);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.product-buy { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 10px; }
.product-price { margin: 0; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.product-price.is-muted { font-weight: 600; font-size: .85rem; white-space: normal; }
.add-button {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; flex: none;
  min-height: 42px; padding: 0 14px; border: 0; border-radius: 999px;
  background: var(--primary); color: var(--on-primary); font-size: .9rem; font-weight: 700; cursor: pointer;
  transition: transform .15s ease, background-color .2s ease;
}
.add-button:active { transform: scale(.96); }
.add-plus { font-size: 1.2rem; line-height: 1; }
.add-button.is-added { background: var(--ink); color: var(--ground); }
.badge {
  position: absolute; top: 10px; left: 10px; z-index: 2; padding: 4px 10px; border-radius: 999px;
  background: var(--secondary); color: var(--on-secondary); font-size: .72rem; font-weight: 800;
}
/* Two cards to a row on a phone: the price on its own line, then a full-width
   add button, so every card lines up the same way. */
@media (max-width: 520px) {
  .product-buy { flex-direction: column; align-items: flex-start; gap: 8px; }
  .add-button { width: 100%; }
}
@media (max-width: 420px) {
  .basket-link .basket-word { display: none; }
  .basket-link { padding: 0 9px; }
  /* A long shop name wraps to two lines instead of being cut off. */
  body.shop .brand-word strong {
    font-size: 1.08rem; max-width: 60vw; line-height: 1.08; white-space: normal;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  }
}

.product-detail { display: grid; gap: clamp(20px, 4vw, 56px); grid-template-columns: 1fr; }
.product-detail[hidden] { display: none; }
@media (min-width: 860px) { .product-detail { grid-template-columns: 1.05fr 1fr; align-items: start; } }
.product-detail-media { aspect-ratio: 1 / 1; overflow: hidden; border-radius: var(--radius); background: var(--surface); }
.product-detail-media img, .product-detail-media .product-media { width: 100%; height: 100%; object-fit: cover; }
.product-detail-copy h2 { font-size: clamp(1.8rem, 1.3rem + 2vw, 2.8rem); }
.detail-price { font-size: 1.6rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.detail-price.is-muted { font-size: 1.05rem; font-weight: 600; }
.detail-desc { max-width: 56ch; color: var(--ink-soft); }
.selector { margin: 18px 0; }
.selector-label { display: block; margin-bottom: 8px; font-weight: 700; }
.option-row { display: flex; flex-wrap: wrap; gap: 8px; }
.option {
  min-width: 48px; min-height: 44px; padding: 0 14px; border-radius: 10px;
  border: 1.5px solid var(--line); background: var(--ground); color: var(--ink); font-weight: 600; cursor: pointer;
}
.option.is-active { border-color: var(--ink); background: var(--ink); color: var(--ground); }
.product-detail-copy .btn--primary { width: 100%; max-width: 440px; margin-top: 10px; }
.detail-note { margin-top: 14px; font-size: .9rem; color: var(--ink-soft); }

.cart-layout, .checkout-layout { display: grid; gap: 20px; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 900px) { .cart-layout, .checkout-layout { grid-template-columns: 1.6fr 1fr; } }
.panel { min-width: 0; padding: clamp(18px, 3vw, 28px); border: 1px solid var(--line); border-radius: var(--radius); background: var(--ground); }
.panel h2 { font-size: 1.35rem; }
.summary-row { display: flex; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.summary .btn { width: 100%; margin-top: 14px; }
.cart-list { display: grid; gap: 4px; }
.cart-line { display: grid; grid-template-columns: 72px minmax(0, 1fr) auto; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.cart-line img, .cart-line .product-media { width: 72px; height: 72px; min-height: 0; border-radius: 10px; object-fit: cover; }
.cart-line h3 { margin: 0 0 4px; font-family: var(--font-body); font-size: 1rem; }
.cart-line p { margin: 0 0 6px; font-size: .88rem; }
.cart-line .cart-unit-price { color: var(--ink-soft); }
.cart-line strong { white-space: nowrap; font-variant-numeric: tabular-nums; }
.qty { display: inline-flex; align-items: center; gap: 4px; padding: 2px; border: 1.5px solid var(--line); border-radius: 999px; }
.qty button { width: 38px; height: 38px; border: 0; border-radius: 999px; background: var(--surface); color: var(--ink); font-size: 1.15rem; cursor: pointer; }
.qty span { min-width: 26px; text-align: center; font-weight: 700; }
.qty .cart-remove {
  width: auto; min-width: 44px; padding-inline: 10px;
  background: transparent; font-size: .86rem; text-decoration: underline;
}
@media (min-width: 361px) and (max-width: 480px) {
  .cart-line > strong { align-self: start; }
}
@media (max-width: 360px) {
  .cart-line { grid-template-columns: 64px minmax(0, 1fr); align-items: start; gap: 10px 12px; }
  .cart-line img, .cart-line .product-media { width: 64px; height: 64px; }
  .cart-line > div { min-width: 0; }
  .cart-line > strong { grid-column: 2; justify-self: start; }
  .cart-line .qty { width: 100%; padding: 0; gap: 2px; border: 0; border-radius: 0; }
  .cart-line .qty button:not(.cart-remove) { width: 32px; height: 32px; }
  .cart-line .qty span { min-width: 20px; }
  .cart-line .qty .cart-remove {
    min-width: 0; height: 32px; margin-left: auto; padding-inline: 4px; font-size: .78rem;
  }
}
.empty-state { padding: clamp(20px, 4vw, 36px); border: 1.5px dashed var(--line); border-radius: var(--radius); text-align: center; }
.empty-state[hidden] { display: none; }
.empty-state h2, .empty-state h3 { font-size: 1.25rem; }
.empty-state p { margin: 0 auto; max-width: 46ch; color: var(--ink-soft); }
.checkout-status h2 { font-size: 1.3rem; }

.about-grid { display: grid; gap: clamp(24px, 5vw, 64px); grid-template-columns: 1fr; align-items: center; }
@media (min-width: 900px) {
  .about-grid { grid-template-columns: 1fr 1fr; }
  .about-grid--solo { grid-template-columns: minmax(0, 760px); }
}
.about-figure { overflow: hidden; border-radius: var(--radius); aspect-ratio: 4 / 3; }
.about-figure img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; object-position: 50% 28%; }
.richtext h2 { font-size: clamp(1.8rem, 1.3rem + 1.8vw, 2.6rem); }
.richtext section { padding-block: 10px 18px; border-bottom: 1px solid var(--line); }
.richtext section h2 { font-size: 1.4rem; }

.contact-grid { display: grid; gap: clamp(20px, 4vw, 56px); grid-template-columns: 1fr; }
@media (min-width: 900px) { .contact-grid { grid-template-columns: 1fr 1fr; } }
.contact-list { display: grid; gap: 2px; }
.contact-item { display: grid; gap: 2px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.contact-item:last-child { border-bottom: 0; }
.contact-item strong { font-size: .76rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft); }
.contact-item a { font-weight: 700; text-decoration: none; overflow-wrap: anywhere; }
.contact-item a:hover { text-decoration: underline; }

.policies-layout { display: grid; gap: 28px; grid-template-columns: 1fr; }
@media (min-width: 900px) { .policies-layout { grid-template-columns: 240px 1fr; } }
.policy-nav { display: flex; flex-wrap: wrap; gap: 8px; align-self: start; }
@media (min-width: 900px) { .policy-nav { position: sticky; top: calc(var(--header-h) + 24px); flex-direction: column; } }
.policy-nav a { padding: 8px 12px; border-radius: 10px; background: var(--surface); font-weight: 600; text-decoration: none; }

.not-found { padding-block: clamp(64px, 12vw, 140px); text-align: center; }
.not-found .lead { margin-inline: auto; }
.not-found-code { margin: 0; font-family: var(--font-display); font-size: clamp(4rem, 3rem + 6vw, 8rem); font-weight: 800; line-height: 1; color: var(--primary-text); }

.toast {
  position: fixed; left: 50%; bottom: 80px; z-index: 60; max-width: calc(100% - 32px);
  padding: 12px 18px; border-radius: 999px; background: var(--ink); color: var(--ground); font-weight: 700;
  opacity: 0; pointer-events: none; transform: translate(-50%, 16px); transition: opacity .2s ease, transform .2s ease;
}
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
@media (min-width: 900px) { .toast { bottom: 32px; } }

/* The shared map widget sits at the end of the visit and contact sections. */
[data-section="visit"] > .sb-location-map--embedded,
[data-section="contact"] > .sb-location-map--embedded {
  width: min(calc(100% - 2 * var(--gutter)), var(--wrap));
  margin: clamp(28px, 4vw, 44px) auto 0;
  border-radius: var(--radius);
  overflow: hidden;
}
