/* ==========================================================================
   Vitamin Horgoš — layout.css (ORBIS rebuild)
   Header, products panel, mobile menu, sections, page hero, grids, footer,
   floating buttons, preloader. Tokens: variables.css
   ========================================================================== */

/* ---------- Header: transparent over the hero, warm-black bar after 40px ---------- */
#site-header { display: contents; }
.hdr {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: var(--z-header);
  color: var(--on-dark);
  transition: background-color var(--dur-hover) var(--ease-out), border-color var(--dur-hover) var(--ease-out);
  border-bottom: 1px solid transparent;
}
.hdr::before { /* keeps light text legible over bright hero images before the bar appears */
  content: "";
  position: absolute;
  inset: 0 0 -40px 0;
  z-index: -1;
  background: linear-gradient(rgba(21, 17, 15, 0.55), rgba(21, 17, 15, 0));
  pointer-events: none;
  transition: opacity var(--dur-hover);
}
.hdr.is-scrolled,
.hdr.menu-open,
body.hdr-solid .hdr {
  background: var(--ground-black);
  border-bottom-color: var(--line-dark-soft);
}
.hdr.is-scrolled::before, .hdr.menu-open::before, body.hdr-solid .hdr::before { opacity: 0; }
.hdr__bar {
  display: flex;
  align-items: center;
  gap: var(--sp-24);
  height: var(--header-h);
  transition: height 350ms var(--ease-out);
}
/* premium 2: the transparent logo, bigger (64px; 48px once the bar is solid). Cream over the film and dark heroes,
   the red brand logo on the solid bar – the two cross-fade with the bar. */
.hdr__logo {
  flex: none;
  display: grid;
  place-items: center;
  min-height: var(--tap);
  border-radius: var(--radius);
}
.hdr__logo picture { display: contents; }
.hdr__logo img { grid-area: 1 / 1; width: auto; height: var(--logo-h); transition: height 350ms var(--ease-out), opacity 350ms var(--ease-out); }
.hdr__logo-c { opacity: 0; }
.hdr.is-scrolled .hdr__logo-w, .hdr.menu-open .hdr__logo-w, body.hdr-solid .hdr .hdr__logo-w { opacity: 0; }
.hdr.is-scrolled .hdr__logo-c, .hdr.menu-open .hdr__logo-c, body.hdr-solid .hdr .hdr__logo-c { opacity: 1; }
@media (min-width: 1280px) {
  .hdr.is-scrolled .hdr__bar { height: 72px; }
  .hdr.is-scrolled .hdr__logo img { height: 48px; }
}

.hdr__nav { flex: 1; display: flex; justify-content: center; }
.hdr__nav > ul { display: flex; align-items: center; gap: clamp(var(--sp-16), 1.6vw, var(--sp-32)); }
.hdr__nav li { position: relative; display: flex; align-items: center; }
.hdr__link {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  font-size: var(--t-ui);
  font-weight: var(--fw-medium);
  letter-spacing: var(--track-ui);
  text-transform: uppercase;
  white-space: nowrap;
  color: var(--on-dark);
  background-image: linear-gradient(var(--gold), var(--gold));
  background-size: 0 1px;
  background-repeat: no-repeat;
  background-position: 0 calc(100% - 10px);
  transition: background-size var(--dur-hover) var(--ease-out), color var(--dur-hover);
}
.hdr__link:hover, .hdr__link[aria-current] { background-size: 100% 1px; }
.hdr__link[aria-current] { color: var(--gold); }
.sub-toggle {
  display: grid;
  place-items: center;
  width: 44px;
  height: var(--tap);
  margin-left: -6px;
  color: var(--on-dark);
}
.sub-toggle .icon { transition: transform var(--dur-hover); }
.has-sub.is-open .sub-toggle .icon { transform: rotate(180deg); }

/* Proizvodi: a plain 9-item panel */
.ppanel {
  position: absolute;
  top: calc(100% + 16px);
  left: 50%;
  width: min(640px, 92vw);
  padding: var(--sp-32);
  border: 1px solid rgba(212, 175, 94, 0.35);   /* a gold hairline */
  border-radius: var(--radius);
  background: #15110F;                         /* opaque: nothing of the hero shows through */
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
  transform: translate(-50%, 8px);
  clip-path: inset(0 -40px 100% -40px round var(--radius));
  visibility: hidden;
  /* opens with a clip + slide, never a fade (a fading panel lets the page behind show through) */
  transition: clip-path 350ms var(--ease-out), transform 350ms var(--ease-out), visibility 0s linear 350ms;
}
.has-sub.is-open .ppanel { visibility: visible; transform: translate(-50%, 0); clip-path: inset(-40px -40px -40px -40px round var(--radius)); transition-delay: 0s; }
.ppanel__title {
  margin-bottom: var(--sp-16);
  font-size: var(--t-eyebrow);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--track-eyebrow);
  text-transform: uppercase;
  color: var(--gold);
}
.ppanel__list { display: grid; grid-template-columns: 1fr 1fr; gap: 0 var(--sp-32); }
.ppanel__item {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--sp-16);
  min-height: 52px;
  padding: var(--sp-12) 0;
  border-bottom: 1px solid var(--line-dark-soft);
  color: var(--on-dark);
  transition: color var(--dur-hover);
}
.ppanel__item:hover { color: var(--gold); }
.ppanel__name { font-family: var(--font-serif); font-size: 1.375rem; line-height: 1.2; }
.ppanel__count { font-size: 0.9375rem; color: var(--on-dark-body); white-space: nowrap; }
.ppanel__all {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-8);
  min-height: var(--tap);
  margin-top: var(--sp-16);
  font-size: var(--t-ui);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--track-ui);
  text-transform: uppercase;
  color: var(--gold);
}

.hdr__actions { flex: none; display: flex; align-items: center; gap: var(--sp-8); }
/* ---------- Language switcher (lang round, js/main.js langSwitch / initLangSwitch): one dropdown in the header and,
   full width, in the mobile menu. Closed: a 52px control (the KONTAKT button's height) with a 1px gold hairline, 6px
   radius, the current language in gold in the middle and a chevron that turns when open. Open: a #15110F panel with a
   35 % gold border drops down in 350ms; the current language carries a gold dot. ---------- */
.lsw { position: relative; margin-right: var(--sp-8); }
.lsw__btn {
  position: relative;
  display: grid;
  place-items: center;
  min-width: 84px;
  min-height: 52px;
  padding: 0 40px 0 24px;
  border: 1px solid var(--gold);
  border-radius: var(--radius);
  color: var(--gold);
  font-size: var(--t-ui);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--track-ui);
  text-transform: uppercase;
  transition: background-color var(--dur-hover) var(--ease-out), color var(--dur-hover) var(--ease-out);
}
.lsw__btn .icon { position: absolute; right: 14px; top: 50%; width: 16px; height: 16px; margin-top: -8px; transition: transform 350ms var(--ease-out); }
.lsw__btn:hover, .lsw.is-open .lsw__btn { background: rgba(212, 175, 94, 0.1); color: var(--on-dark); }
.lsw.is-open .lsw__btn .icon { transform: rotate(180deg); }
.lsw__btn:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.lsw__list {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 5;
  min-width: 220px;
  margin: 0;
  padding: var(--sp-8);
  list-style: none;
  border: 1px solid rgba(212, 175, 94, 0.35);
  border-radius: var(--radius);
  background: #15110F;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
  visibility: hidden;
  transform: translate3d(0, -8px, 0);
  clip-path: inset(0 -40px 100% -40px round var(--radius));
  transition: clip-path 350ms var(--ease-out), transform 350ms var(--ease-out), visibility 0s linear 350ms;
}
.lsw.is-open .lsw__list { visibility: visible; transform: none; clip-path: inset(-40px -40px -40px -40px round var(--radius)); transition: clip-path 350ms var(--ease-out), transform 350ms var(--ease-out), visibility 0s; }
.lsw__opt {
  display: flex;
  align-items: center;
  gap: var(--sp-8);
  min-height: 48px;
  padding: 0 var(--sp-16) 0 var(--sp-12);
  border-radius: var(--radius);
  color: var(--on-dark);
  font-size: 1.125rem;
  cursor: pointer;
  transition: background-color var(--dur-micro) var(--ease-out), color var(--dur-micro) var(--ease-out);
}
.lsw__opt:hover, .lsw__opt:focus { outline: none; background: rgba(212, 175, 94, 0.12); }
.lsw__opt:focus-visible { box-shadow: inset 0 0 0 2px var(--gold); }
.lsw__dot { flex: none; width: 8px; height: 8px; border-radius: 50%; }
.lsw__opt[aria-selected="true"] { color: var(--gold); }
.lsw__opt[aria-selected="true"] .lsw__dot { background: var(--gold); }
.lsw__code { font-weight: var(--fw-semibold); letter-spacing: var(--track-ui); }
.lsw__sep { color: var(--on-dark-body); }
/* the mobile menu: the same control, full width */
.lsw--block { flex: 1 1 100%; margin: 0; }
.lsw--block .lsw__btn { width: 100%; font-size: 1.125rem; }
.lsw--block .lsw__list { left: 0; right: 0; }
/* opens upward in the mobile menu when it sits at the bottom of the screen */
.lsw--block .lsw__list { top: auto; bottom: calc(100% + 8px); transform: translate3d(0, 8px, 0); clip-path: inset(100% -40px 0 -40px round var(--radius)); }
.lsw--block.is-open .lsw__list { transform: none; }
.hdr__contact { margin-right: var(--sp-8); }
.hdr__icon {
  position: relative;
  display: grid;
  place-items: center;
  width: var(--tap);
  height: var(--tap);
  border-radius: var(--radius);
  color: var(--on-dark);
  transition: color var(--dur-hover), background-color var(--dur-hover);
}
.hdr__icon .icon { width: 22px; height: 22px; }
.hdr__icon:hover, .hdr__icon[aria-current] { color: var(--gold); }
/* text label for each icon (hover and keyboard focus); the accessible name is the same text */
.hdr__tip {
  position: absolute;
  top: calc(100% + 6px);
  left: 50%;
  padding: 4px 10px;
  border-radius: var(--radius);
  background: var(--cream);
  color: var(--ink);
  font-size: 0.8125rem;
  font-weight: var(--fw-semibold);
  white-space: nowrap;
  transform: translate(-50%, -4px);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--dur-hover), transform var(--dur-hover);
  clip-path: inset(0);
}
.hdr__icon:hover .hdr__tip,
.hdr__icon:focus-visible .hdr__tip { opacity: 1; transform: translate(-50%, 0); }
/* hidden from view but kept as the button's name when not hovered */
.hdr__icon:not(:hover):not(:focus-visible) .hdr__tip { clip-path: inset(50%); }
.hdr__badge {
  position: absolute;
  top: 4px;
  right: 2px;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  border-radius: var(--radius);
  background: var(--red);
  color: #fff;
  font-size: 0.75rem;
  font-weight: var(--fw-semibold);
  line-height: 20px;
  text-align: center;
}
.hdr__icon-label { display: none; }

.burger {
  display: none;
  align-items: center;
  gap: var(--sp-8);
  min-height: var(--tap);
  padding: 0 var(--sp-16);
  border: 1px solid var(--line-dark);
  border-radius: var(--radius);
  color: var(--on-dark);
  font-size: var(--t-ui);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--track-ui);
  text-transform: uppercase;
}
.burger .icon { width: 22px; height: 22px; }

/* ---------- Mobile menu: full screen, 24px items ---------- */
.mnav {
  position: fixed;
  inset: var(--header-h) 0 0 0;
  z-index: -1;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--ground-black);
  color: var(--on-dark);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--dur-hover), visibility 0s linear var(--dur-hover);
}
.mnav.is-open { opacity: 1; visibility: visible; transition-delay: 0s; }
.mnav__inner { padding-block: var(--sp-24) calc(var(--sp-48) + var(--safe-b)); }
.mnav__list > li { border-bottom: 1px solid var(--line-dark-soft); }
.mnav__row { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-16); }
.mnav__link {
  display: flex;
  align-items: center;
  gap: var(--sp-12);
  min-height: 64px;
  font-family: var(--font-serif);
  font-size: 1.75rem;
  line-height: 1.2;
  color: var(--on-dark);
}
.mnav__link[aria-current] { color: var(--gold); }
.mnav__toggle {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-8);
  min-height: var(--tap);
  padding: 0 var(--sp-12);
  border: 1px solid var(--line-dark);
  border-radius: var(--radius);
  color: var(--gold);
  font-size: 0.9375rem;
  font-weight: var(--fw-semibold);
}
.mnav__toggle[aria-expanded="true"] .icon { transform: rotate(45deg); }
.mnav__sub { padding: 0 0 var(--sp-16) var(--sp-16); }
.mnav__sub a { display: flex; align-items: center; min-height: 52px; font-size: 1.25rem; color: var(--on-dark-body); }
.mnav__sub a:hover { color: var(--gold); }
.mnav__more { display: grid; grid-template-columns: 1fr 1fr; gap: 0 var(--sp-24); margin-top: var(--sp-32); }
.mnav__minor { display: flex; align-items: center; gap: var(--sp-8); min-height: 52px; font-size: 1.125rem; color: var(--on-dark-body); }
.mnav__minor[aria-current] { color: var(--gold); }
.mnav__count { min-width: 22px; height: 22px; padding: 0 6px; border-radius: var(--radius); background: var(--red); color: #fff; font-size: 0.75rem; line-height: 22px; text-align: center; }
.mnav__count:empty, .mnav__count[hidden] { display: none; }
.mnav__foot { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-16) var(--sp-32); margin-top: var(--sp-32); padding-top: var(--sp-24); border-top: 1px solid var(--line-dark-soft); }
.mnav__foot > a { min-height: var(--tap); display: inline-flex; align-items: center; color: var(--on-dark-body); }

/* ---------- Main and sections ---------- */
main { display: block; }
main:focus { outline: none; }

/* Fixed section rhythm (premium 10, item 6): 160 / 112 / 80px top and bottom on every section; the old
   tight / large modifiers resolve to the same value. Thin typographic strips are .band, not .section. */
.section, .section--tight, .section--pad-lg { position: relative; padding-block: var(--section-y); }
.section--black, .section--dark { background: var(--ground-black); }
.section--burgundy, .section--deeper { background: var(--ground-burgundy); }
.section--cream { background: var(--cream); }
.section--white, .section--paper { background: var(--warm-white); }

/* Section header row (premium 10, item 6): gold 15px eyebrow with a hairline underline on the left, the
   section number (01, 02 … restarted per page; main.js renumbers the visible ones) on the right.
   Always a direct child of the section's .container so the number sits on the container's right edge. */
.shead { grid-column: 1 / -1; display: flex; align-items: flex-end; justify-content: space-between; gap: var(--sp-24); margin-bottom: var(--sp-48); }
.shead .eyebrow { margin: 0; }
.shead__no {
  flex: none;
  padding-bottom: var(--sp-8);
  font-family: var(--font-sans);
  font-size: var(--t-eyebrow);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--track-eyebrow);
  line-height: 1.4;
  color: var(--gold-ink);
  font-variant-numeric: tabular-nums lining-nums;
}
.shead--center { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); }
.shead--center .eyebrow { grid-column: 2; text-align: center; }
.shead--center .shead__no { grid-column: 3; justify-self: end; }
:is(.on-dark, .section--black, .section--dark, .section--burgundy) .shead__no { color: var(--gold); }

/* Thin typographic bands between sections (signature line, trust strip): not numbered, own padding */
.band { position: relative; padding-block: var(--sp-48); }

.section__head { display: grid; gap: var(--sp-24); margin-bottom: var(--sp-64); max-width: 46rem; }
.section__head--center { margin-inline: auto; text-align: center; justify-items: center; }
.section__head--split { max-width: none; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: end; gap: var(--sp-48); }
.section__head .lead { margin: 0; }
.section__title { font-size: var(--t-h2); }

.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(var(--sp-48), 6vw, var(--sp-96)); align-items: center; }
.split--top { align-items: start; }
.split--wide-media { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }

/* ---------- Grids ---------- */
.grid { display: grid; gap: var(--sp-32); }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid--auto { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }

/* ---------- Page hero (every inner page): full-bleed image, overlay, centred eyebrow + serif title ---------- */
.phero {
  position: relative;
  isolation: isolate;
  display: grid;
  align-items: center;
  min-height: min(78vh, 760px);
  padding: calc(var(--header-h) + var(--sp-64)) 0 var(--sp-96);
  background: var(--ground-black);
  color: var(--on-dark);
  text-align: center;
  overflow: hidden;
}
.phero--short { min-height: 0; padding-bottom: var(--sp-64); }
.phero__media, .phero__media img, .phero__media video {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.phero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--hero-overlay);
}
.phero__inner { display: grid; justify-items: center; gap: var(--sp-24); }
/* final polish §4: on phones every hero button is full width, stacked */
@media (max-width: 480px) {
  .phero__actions { flex-direction: column; align-items: stretch; width: 100%; }
  .phero__actions .btn { width: 100%; }
}

/* ---------- Premium 3: the owner's background images (assets/images/pozadina, see _tools/images/) in every inner hero.
   Product bags on a rustic board on the right, a calm dark area on the left. Cover, a focus per image so the packs stay
   in frame, a very slow Ken Burns (1 → 1.05 over 20 s, off under reduced motion), and an Orbis overlay: a dark scrim
   behind the centred text, heavier at the bottom, so every line of the hero stays ≥ 7:1 (checked on the rendered
   pixels by _tools/qa/contrast-rendered.mjs). ---------- */
.phero__bg { overflow: hidden; }
.phero__bg img { object-position: var(--bg-focus); transform-origin: var(--bg-focus); animation: phero-kb 20s var(--ease-out) both; }
.phero__bg--1 { --bg-focus: 68% 60%; }
.phero__bg--2 { --bg-focus: 64% 58%; }
.phero__bg--3 { --bg-focus: 66% 60%; }
/* the hero's body text in near-full cream over the photo (the plain dark grounds keep 76 %) */
.phero--bg { --on-dark-body: rgba(245, 240, 232, 0.92); }
.phero--bg .phero__lead { color: var(--on-dark); }
.phero--bg .chip { background: rgba(21, 17, 15, 0.8); }
@keyframes phero-kb { from { transform: scale(1); } to { transform: scale(1.05); } }
.phero.phero--bg::after {
  background:
    radial-gradient(ellipse 62% 58% at 50% 56%, rgba(21, 17, 15, 0.7) 0%, rgba(21, 17, 15, 0.38) 62%, rgba(21, 17, 15, 0) 100%),
    linear-gradient(180deg, rgba(21, 17, 15, 0.82) 0%, rgba(21, 17, 15, 0.5) 34%, rgba(21, 17, 15, 0.58) 66%, rgba(21, 17, 15, 0.92) 100%),
    linear-gradient(90deg, rgba(74, 14, 18, 0.3) 0%, rgba(74, 14, 18, 0) 55%);
}
.phero--bg.phero--short { min-height: min(62vh, 600px); }
/* desktop: the images keep a calm dark area on the left and the packs on the right, so the text sits on the left
   (as on the category hero) and the overlay is heaviest there; the packs stay visible on the right */
@media (min-width: 1024px) {
  .phero--bg:not(.phero--cat) .phero__inner { justify-items: start; text-align: left; }
  .phero--bg:not(.phero--cat) .phero__inner > * { max-width: 42rem; }
  .phero--bg:not(.phero--cat) :is(.crumbs ol, .phero__actions, .phero__meta, .rhero__meta) { justify-content: flex-start; }
  .phero.phero--bg:not(.phero--cat) .phero__title::after { left: 0; margin-left: 0; transform-origin: 0 50%; }
  .phero.phero--bg::after {
    background:
      linear-gradient(90deg, rgba(21, 17, 15, 0.94) 0%, rgba(21, 17, 15, 0.92) 40%, rgba(21, 17, 15, 0.66) 62%, rgba(21, 17, 15, 0.44) 100%),
      linear-gradient(180deg, rgba(21, 17, 15, 0.62) 0%, rgba(21, 17, 15, 0) 30%, rgba(21, 17, 15, 0) 68%, rgba(21, 17, 15, 0.88) 100%),
      linear-gradient(90deg, rgba(74, 14, 18, 0.28) 0%, rgba(74, 14, 18, 0) 50%);
  }
}
@media (max-width: 700px) {
  .phero--bg, .phero--bg.phero--short { min-height: 70vh; min-height: 70svh; }
  /* phones: the crop moves left onto the spoon and the powder (the packs only partly in frame), and the centred text
     gets a heavier scrim */
  .phero__bg--1 { --bg-focus: 46% 60%; }
  .phero__bg--2 { --bg-focus: 42% 58%; }
  .phero__bg--3 { --bg-focus: 46% 60%; }
  .phero.phero--bg::after {
    background:
      radial-gradient(ellipse 100% 62% at 50% 56%, rgba(21, 17, 15, 0.8) 0%, rgba(21, 17, 15, 0.62) 72%, rgba(21, 17, 15, 0.42) 100%),
      linear-gradient(180deg, rgba(21, 17, 15, 0.88) 0%, rgba(21, 17, 15, 0.6) 30%, rgba(21, 17, 15, 0.66) 68%, rgba(21, 17, 15, 0.95) 100%);
  }
}
.phero__title { max-width: 18ch; color: var(--on-dark); font-size: var(--t-h1); }
.phero__title--md { font-size: var(--t-h2); }
.phero__lead { max-width: 38rem; font-size: var(--t-lead); line-height: 1.6; color: var(--on-dark-body); }
.phero__actions, .phero__meta { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--sp-16); margin-top: var(--sp-8); }

/* Breadcrumbs: gold eyebrow style */
.crumbs ol { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--sp-4) var(--sp-8); }
.crumbs li { display: inline-flex; align-items: center; gap: var(--sp-8); font-size: var(--t-eyebrow); font-weight: var(--fw-semibold); letter-spacing: var(--track-eyebrow); text-transform: uppercase; }
.crumbs li + li::before { content: "/"; color: var(--gold-soft); }
.crumbs a { display: inline-flex; align-items: center; min-height: 40px; color: var(--gold); text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 5px; transition: text-decoration-color var(--dur-hover); }
.crumbs a:hover { text-decoration-color: currentColor; }
.crumbs [aria-current] { color: var(--on-dark-body); }
.crumbs--light a { color: var(--gold-ink); }
.crumbs--light [aria-current] { color: var(--ink-body); }

/* ---------- Footer: warm black, newsletter row, 4 columns, legal row ---------- */
#site-footer { display: block; }
/* premium 2: dark wood under a 74–80 % warm-black veil (texture from _tools/textures), the red wave on top (.wave-top, brand.css).
   The wood is requested only once the footer comes within about a screen (.is-near, main.js), so it stays off the LCP path. */
.ftr {
  position: relative;
  background:
    linear-gradient(rgba(21, 17, 15, 0.74), rgba(21, 17, 15, 0.8)),
    var(--ground-black);
  color: var(--on-dark-body);
  /* the bottom keeps clear of the floating „Pitajte nas“ / back-to-top buttons at every width (premium 3) */
  padding-block: var(--sp-96) calc(var(--sp-24) + var(--btn-h) + var(--fab-bottom) + var(--sp-16));
  --wave-color: var(--red);
}
.ftr.is-near {
  background:
    linear-gradient(rgba(21, 17, 15, 0.74), rgba(21, 17, 15, 0.8)),
    url("../assets/textures/wood-dark.webp") center / cover,
    var(--ground-black);
}
.ftr__label {
  margin-bottom: var(--sp-24);
  font-size: 0.6875rem;            /* final polish §3.7: 11px gold uppercase, 0.18em tracking */
  font-weight: var(--fw-semibold);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
}
.ftr__news {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
  align-items: end;
  gap: var(--sp-48);
  padding-bottom: var(--sp-64);
  margin-bottom: var(--sp-64);
  border-bottom: 1px solid var(--line-dark-soft);
}
.ftr__news .ftr__label { margin-bottom: var(--sp-12); }
.ftr__news-title { font-family: var(--font-serif); font-size: var(--t-h3); line-height: 1.2; color: var(--on-dark); }
.ftr__form { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: var(--sp-16); }
.ftr__form .field { margin: 0; }
.ftr__grid { display: grid; grid-template-columns: 1.15fr 1fr 1fr 1.25fr 1.1fr; gap: var(--sp-48) var(--sp-40, 40px); }
/* the footer is laid out only once it comes near (it is the biggest block on every page); the reserved heights are the
   measured ones per breakpoint, and "auto" keeps the real height once it has rendered. The wave sits on .ftr, outside these. */
.ftr__news, .ftr__grid, .ftr__bottom { content-visibility: auto; }
.ftr__news { contain-intrinsic-block-size: auto 151px; }
.ftr__grid { contain-intrinsic-block-size: auto 578px; }
.ftr__bottom { contain-intrinsic-block-size: auto 59px; }
@media (max-width: 1024px) {
  .ftr__news { contain-intrinsic-block-size: auto 268px; }
  .ftr__grid { contain-intrinsic-block-size: auto 1356px; }
  .ftr__bottom { contain-intrinsic-block-size: auto 80px; }
}
@media (max-width: 640px) {
  .ftr__news { contain-intrinsic-block-size: auto 344px; }
  .ftr__grid { contain-intrinsic-block-size: auto 2150px; }
  .ftr__bottom { contain-intrinsic-block-size: auto 150px; }
}
.ftr__logo { display: inline-grid; place-items: center; min-height: var(--tap); }
.ftr__logo img { width: auto; height: 80px; }
.ftr__since { margin-top: var(--sp-16); font-family: var(--font-serif); font-style: italic; font-weight: var(--fw-light); font-size: 1.75rem; line-height: 1.2; color: var(--gold); }
.ftr__linkbtn { display: inline-flex; align-items: center; gap: var(--sp-12); min-height: var(--tap); padding: 0; border: 0; background: none; font: inherit; font-size: 1.125rem; color: var(--on-dark-body); cursor: pointer; transition: color var(--dur-hover); }
.ftr__linkbtn:hover { color: var(--gold); }
.ftr__kbd { padding: 1px 6px; border: 1px solid var(--line-dark); border-radius: var(--radius); font-family: inherit; font-size: 0.8125rem; letter-spacing: 0.04em; color: var(--on-dark-body); }
.ftr__tagline { margin-top: var(--sp-8); max-width: 22rem; font-size: 1rem; }
.ftr__social { display: flex; gap: var(--sp-8); margin-top: var(--sp-24); }
.social-btn {
  display: grid;
  place-items: center;
  width: var(--tap);
  height: var(--tap);
  border: 1px solid var(--line-dark);
  border-radius: var(--radius);
  color: var(--on-dark);
  transition: color var(--dur-hover), border-color var(--dur-hover);
}
.social-btn:hover { color: var(--gold); border-color: var(--gold); }
.ftr__links li + li { margin-top: var(--sp-4); }
.ftr__links a { display: inline-flex; align-items: center; min-height: 40px; font-size: 1.125rem; color: var(--on-dark); transition: color var(--dur-hover); } /* 18px cream */
.ftr__links a:hover, .ftr__contact a:hover { color: var(--gold); }
.ftr__links--sm li { font-size: 1.125rem; }
.ftr__links--sm span { display: block; color: var(--on-dark-body); }
.ftr__links--sm li { padding-block: var(--sp-4); }
.ftr__contact { font-style: normal; font-size: 1.125rem; line-height: 1.7; }
.ftr__line { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: var(--sp-12); align-items: start; }
.ftr__line > .icon { width: 22px; height: 22px; margin-top: 0.3em; color: var(--gold); }
.ftr__contact p + p { margin-top: var(--sp-16); }
.ftr__contact a { display: inline-block; min-height: 32px; color: var(--on-dark); }
.ftr__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--sp-16) var(--sp-32);
  margin-top: var(--sp-64);
  padding-top: var(--sp-32);
  border-top: 1px solid var(--line-dark-soft);
  font-size: 0.9375rem;
}
.ftr__legal { display: flex; gap: var(--sp-24); }
.ftr__legal a { text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--line-dark); }
.ftr__legal a:hover { color: var(--gold); }
/* premium 3: the closing hairline row (year · the brand line in italic · back to the top) and the faint watermark */
.ftr > .container { position: relative; z-index: 1; }
.ftr__sign {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-16) var(--sp-32);
  margin-top: var(--sp-32);
  padding-top: var(--sp-24);
  border-top: 1px solid var(--line-dark);
  font-size: 0.9375rem;
}
.ftr__script { font-family: var(--font-serif); font-size: 1.5rem; font-style: italic; font-weight: var(--fw-light, 300); line-height: 1.2; color: var(--gold); }
.ftr__top {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-8);
  min-height: var(--tap);
  padding: 0 var(--sp-16);
  border: 1px solid var(--line-dark);
  border-radius: var(--radius);
  color: var(--on-dark);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--track-eyebrow);
  text-transform: uppercase;
  font-size: 0.875rem;
  transition: border-color var(--dur-hover) var(--ease-out), color var(--dur-hover) var(--ease-out);
}
.ftr__top .icon { width: 18px; height: 18px; transition: transform var(--dur-hover) var(--ease-out); }
.ftr__top:hover, .ftr__top:focus-visible { border-color: var(--gold); color: var(--gold); }
.ftr__top:hover .icon, .ftr__top:focus-visible .icon { transform: translateY(-3px); }
.ftr__mark {
  position: absolute;
  right: 0;
  bottom: 0.12em;
  z-index: 0;
  font-family: var(--font-serif);
  font-size: clamp(6rem, 17vw, 17rem);
  font-weight: var(--fw-light, 300);
  line-height: 0.8;
  white-space: nowrap;
  color: rgba(245, 240, 232, 0.035);
  pointer-events: none;
  user-select: none;
  overflow: hidden; /* the glyph box is taller than the 0.8 line: it must not lengthen the page under the footer */
}
.ftr__mark::before { content: attr(data-mark); }
@media (max-width: 640px) {
  .ftr__sign { flex-direction: column; align-items: flex-start; }
}

/* ---------- Floating: „Pitajte nas“ bottom-left, back to top bottom-right, both 56px ---------- */
.asst-fab, .to-top {
  position: fixed;
  bottom: calc(var(--fab-bottom) + var(--safe-b));
  z-index: var(--z-fab);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-8);
  height: var(--btn-h);
  border: 1px solid var(--gold);
  border-radius: var(--radius);
  background: var(--ground-black);
  color: var(--on-dark);
  box-shadow: var(--shadow-lifted);
  transition: border-color var(--dur-hover), color var(--dur-hover), opacity var(--dur-hover), transform var(--dur-hover);
}
.asst-fab { left: calc(var(--fab-bottom) + var(--safe-l)); padding: 0 var(--sp-24) 0 var(--sp-16); font-size: var(--t-ui); font-weight: var(--fw-semibold); letter-spacing: var(--track-ui); text-transform: uppercase; }
.asst-fab__icon { display: grid; color: var(--gold); }
.asst-fab:hover, .to-top:hover { color: var(--gold); }
.to-top { right: calc(var(--fab-bottom) + var(--safe-r)); width: var(--btn-h); opacity: 0; visibility: hidden; transform: translateY(8px); }
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; }
.to-top .icon { width: 22px; height: 22px; }
html.drawer-open .asst-fab, html.drawer-open .to-top,
html.modal-open .asst-fab, html.modal-open .to-top { opacity: 0; visibility: hidden; }

/* ---------- Preloader: the particle intro on every page load (js/intro.js) ----------
   The inline <style id="vh-pre-css"> in every <head> already draws the overlay (fixed, z-index 1200, the opaque
   ground, a CSS fail-safe), so no page ever shows before it; this block repeats the ground and styles its contents
   and the exit. The page renders and paints underneath the whole time (LCP never waits for the intro).
   Stacking: 1200 = above every layer of the page – header (100), floating buttons (90), assistant (200), modals
   and search (300–302), lightbox / fly-to-cart (--z-veil 1000) and the skip link (--z-cursor 1100).
   The ground is fully opaque: nothing of the page shows through until the curtain lifts. */
.preloader {
  position: fixed;
  inset: 0;
  z-index: var(--z-intro);
  display: grid;
  place-items: center;
  background: radial-gradient(ellipse 75% 65% at 50% 45%, rgba(74, 14, 18, 0.9), rgba(74, 14, 18, 0.45) 40%, rgba(74, 14, 18, 0) 72%), #15110F;
  will-change: transform;
}
/* the curtain's soft lower edge: waits below the viewport and follows the overlay up during the exit */
.preloader::after { content: ""; position: absolute; left: 0; right: 0; top: 100%; height: 24vh; background: linear-gradient(#15110F, rgba(21, 17, 15, 0.82) 35%, rgba(21, 17, 15, 0)); pointer-events: none; }
.preloader__cv { position: absolute; inset: 0; width: 100%; height: 100%; }
.preloader__glow { position: absolute; inset: 0; opacity: 0; will-change: opacity; pointer-events: none; }
/* static logo (reduced motion, or no canvas): the transparent logo, in the box the particles form. In the particle
   intro the crisp logo is drawn into the canvas instead, so it is never a DOM image (and never the page's LCP). */
.preloader__logo { position: relative; width: min(40vw, 460px); aspect-ratio: 346 / 240; transform: translateY(-4vh); opacity: 0; }
/* is-crisp: on file:// the crisp logo of the particle intro is this element (js/intro.js animates its opacity) */
.preloader__logo.is-crisp { background: url("../assets/logo-transparent@2x.png") center / contain no-repeat; background-image: image-set(url("../assets/logo-transparent@2x.webp") type("image/webp"), url("../assets/logo-transparent@2x.png") type("image/png")); }
.preloader.is-calm .preloader__logo { opacity: 1; background: url("../assets/logo-transparent@2x.png") center / contain no-repeat; background-image: image-set(url("../assets/logo-transparent@2x.webp") type("image/webp"), url("../assets/logo-transparent@2x.png") type("image/png")); }
/* the exit: a soft upward curtain over --pre-out (600ms, 450ms after a skip); the canvas fades its particles itself */
.preloader.is-leaving { pointer-events: none; transform: translate3d(0, calc(-100% - 24vh), 0); transition: transform var(--pre-out, 600ms) var(--ease-in-out); }
.preloader.is-leaving.is-held { pointer-events: auto; } /* until the tap that skipped has ended */
.preloader.is-leaving .preloader__logo { opacity: 0; transition: opacity var(--pre-out, 600ms) var(--ease-in-out); }
.no-js .preloader, [data-intro="off"] .preloader { display: none; }
@media (max-width: 699px) { .preloader__logo { width: 70vw; } }
/* reduced motion: no curtain – the static logo and its ground fade out in place (300ms, linear) */
@media (prefers-reduced-motion: reduce) {
  .phero__bg img { animation: none; }
}
@media (prefers-reduced-motion: reduce) {
  .preloader { will-change: auto; }
  .preloader.is-leaving { transform: none; opacity: 0; transition: opacity var(--pre-out, 300ms) linear; }
  .preloader.is-leaving .preloader__logo { transition: none; opacity: 1; }
}
/* Page change (§7): the page fades to warm black in 350ms under the header, then the browser navigates;
   the next page opens on the preloader overlay */
.veil { position: fixed; inset: 0; z-index: calc(var(--z-header) - 1); background: var(--ground-black); opacity: 0; visibility: hidden; pointer-events: none; transition: opacity 350ms var(--ease-in-out), visibility 0s linear 350ms; }
.veil.is-on { opacity: 1; visibility: visible; pointer-events: auto; transition: opacity 350ms var(--ease-in-out); }

/* ---------- Retired decorations (markup may still carry them on some pages) ---------- */
.ghost, .deco, .sweep, .grain::after, .phero__stack, .phero__line, .tod-greet, .intro { display: none !important; }

/* ---------- Responsive ---------- */
@media (max-width: 1279px) {
  .hdr .hdr__nav, .hdr .lsw--hdr, .hdr .hdr__contact { display: none; }
  .burger { display: inline-flex; }
  .hdr__actions { margin-left: auto; }
}
@media (max-width: 1024px) {
  .grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split, .split--wide-media { grid-template-columns: minmax(0, 1fr); }
  .section__head--split { grid-template-columns: minmax(0, 1fr); align-items: start; gap: var(--sp-24); }
  .ftr__grid { grid-template-columns: 1fr 1fr; }
  .ftr__brand { grid-column: 1 / -1; }
  .ftr__news { grid-template-columns: minmax(0, 1fr); }
}
/* 1280–1439: the comparison icon (it also sits in the menu and on product cards) makes room for the six links */
@media (max-width: 1439px) { .hdr .hdr__cmp { display: none; } }
@media (max-width: 640px) {
  .hdr .hdr__fav, .hdr .hdr__cmp, .hdr #hdr-user { display: none; } /* reachable from the menu, with labels */
  .hdr__bar { gap: var(--sp-12); }
  .grid--2, .grid--3, .grid--4 { grid-template-columns: minmax(0, 1fr); }
  .ftr__grid { grid-template-columns: minmax(0, 1fr); gap: var(--sp-48); }
  .ftr__form { grid-template-columns: minmax(0, 1fr); }
  .mnav__more { grid-template-columns: minmax(0, 1fr); }
  .phero { min-height: 70vh; padding-bottom: calc(var(--sp-48) + var(--btn-h) + var(--fab-bottom)); } /* hero buttons end above „Pitajte nas“ */
  .asst-fab__label { font-size: 0.875rem; }
}
@media (max-width: 380px) {
  .burger__label { font-size: 0.875rem; }
  .burger { padding: 0 var(--sp-12); }
}
@media (prefers-reduced-motion: reduce) {
  .hdr, .hdr__bar, .hdr__logo img, .ppanel, .mnav, .to-top { transition: none; }
}
