/* ============================================================================
   Pužin Studio Kuhinja — public landing page
   Scandinavian minimal: paper ground, ink type, hairline rules.
   No shadows, no gradients, no accent colour; the only icons are the
   footer's three social links, in the text grey.

   Written mobile-first. Two structural breakpoints:
     base            phone           (design width 390px)
     min-width 640   tablet          (content swaps back to the "wide" variants)
     min-width 900   desktop         (design width 1280px)
   The header alone switches to its desktop row at 1024 (see header / nav).
   Everything between the two designed widths is interpolated with clamp(),
   fitted so the min lands exactly on the 390px value and the max exactly on
   the 1280px value.
   ========================================================================= */

/* --------------------------------------------------------------- tokens -- */

:root {
  /* colour ----------------------------------------------------------------
     Neutral grey, no warm tint anywhere: the client read the old beige cast
     as "dirty white". Same lightness ladder as before, hue removed, so every
     contrast ratio the design was checked against is preserved. */
  --paper: #FAFAFA;
  --paper-tinted: #EDEDED;
  --ink: #1E1E1E;
  --ink-hover: #383838;
  --text-secondary: #6B6B6B;
  --text-tertiary: #474747;
  --muted: #8A8A8A;
  --rule: #E3E3E3;
  --rule-strong: #D2D2D2;

  /* geometry -------------------------------------------------------------- */
  --maxw: 1280px;
  --gutter: clamp(20px, 7.73px + 3.146vw, 48px);   /* 20 -> 48 */
  /* The header row's exact height (its hairline is the 1px on top of it).
     The hero media is sized as "the rest of the screen" from this token. */
  --header-h: clamp(68px, 59.236px + 2.247vw, 88px); /* 68 -> 88 */
  --radius-pill: 999px;
  --radius-photo: 4px;
  --hairline: 1px solid var(--rule);

  /* type ------------------------------------------------------------------ */
  --font: 'Schibsted Grotesk', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --fs-h1: clamp(33px, 24.674px + 2.135vw, 52px);
  --ls-h1: clamp(-1.4px, -0.537px - 0.067vw, -0.8px);
  --fs-h2: clamp(26px, 22.494px + 0.899vw, 34px);
  --ls-h2: clamp(-0.8px, -0.369px - 0.034vw, -0.5px);
  --fs-h2-cta: clamp(28px, 22.742px + 1.348vw, 40px);
  --ls-h2-cta: clamp(-1px, -0.425px - 0.045vw, -0.6px);

  --fs-hero-body: clamp(15px, 14.343px + 0.169vw, 16.5px);
  --fs-body: clamp(14px, 13.343px + 0.169vw, 15.5px);
  --fs-small: clamp(13px, 12.781px + 0.056vw, 13.5px);
  --fs-usp-title: 14.5px;
  --fs-card-title: clamp(15px, 14.562px + 0.112vw, 16px);
  --fs-nav: 13.5px;
  --nav-gap: 28px;
  --fs-btn: clamp(14px, 14.719px - 0.056vw, 14.5px);    /* 14.5 phone -> 14 desktop */

  --fs-eyebrow: clamp(10.5px, 10.062px + 0.112vw, 11.5px);
  --ls-eyebrow: clamp(2px, 1.912px + 0.022vw, 2.2px);
  --fs-stat: clamp(22px, 18.494px + 0.899vw, 30px);
  --ls-stat: clamp(-0.5px, 0.219px - 0.056vw, 0px);
  --fs-stat-label: clamp(10px, 9.343px + 0.169vw, 11.5px);
  --ls-stat-label: clamp(1.2px, 1.025px + 0.045vw, 1.6px);
  --fs-step-number: clamp(11px, 10.562px + 0.112vw, 12px);
  --ls-step-number: clamp(1px, 0.781px + 0.056vw, 1.5px);
  --fs-caption: clamp(12px, 11.562px + 0.112vw, 13px);
  --fs-copyright: clamp(11.5px, 11.281px + 0.056vw, 12px);
  /* logo lockup: the name; the tag beside or under it is sized in ems of it */
  --fs-logo-name: clamp(30px, 27.371px + 0.674vw, 36px);          /* 30 -> 36 */
  --fs-footer: clamp(13px, 12.781px + 0.056vw, 13.5px);

  /* rhythm ---------------------------------------------------------------- */
  --pad-page-head: clamp(40px, 25.98px + 3.596vw, 72px);  /* 40 -> 72  */
  --pad-hero-intro: clamp(40px, 22.47px + 4.494vw, 80px); /* 40 -> 80  */
  --pad-about-top: clamp(36px, 13.21px + 5.843vw, 88px);  /* 36 -> 88  */
  --pad-about-bottom: clamp(40px, 18.97px + 5.393vw, 88px);/* 40 -> 88 */
  --pad-process: clamp(36px, 16.72px + 4.944vw, 80px);    /* 36 -> 80  */
  --pad-closing: clamp(44px, 19.46px + 6.292vw, 100px);   /* 44 -> 100 */
  --pad-footer-top: clamp(32px, 23.24px + 2.247vw, 52px); /* 32 -> 52  */
  --pad-footer-bottom: clamp(32px, 28.5px + 0.899vw, 40px);

  --gap-gallery: clamp(14px, 10.5px + 0.899vw, 22px);     /* 14 -> 22  */
  --gap-stats: clamp(28px, 15.73px + 3.146vw, 56px);      /* 28 -> 56  */

  --transition: 150ms ease;
}

/* ---------------------------------------------------------------- reset -- */

*,
*::before,
*::after { box-sizing: border-box; }

html {
  overflow-x: hidden;               /* belt-and-braces: never scroll sideways */
  -webkit-text-size-adjust: 100%;
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-weight: 400;
  font-size: var(--fs-body);
  line-height: 1.7;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, p, figure, ul, ol, dialog { margin: 0; padding: 0; }
ul, ol { list-style: none; }

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

/* one focus treatment for every interactive element on the page */
a:focus-visible,
button:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

main section[id],
footer[id] { scroll-margin-top: var(--header-h); }

/* ------------------------------------------------------- layout helpers -- */

.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Desktop / phone copy variants. Both are rendered; CSS decides which one
   is shown so the CMS keeps a single source for each string. */
.only-phone { display: none !important; }

@media (max-width: 639.98px) {
  .only-wide { display: none !important; }
  .only-phone { display: revert !important; }
}

/* --------------------------------------------------------------- shared -- */

.section-heading {
  font-size: var(--fs-h2);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: var(--ls-h2);
  text-wrap: balance;
}

.eyebrow {
  font-size: var(--fs-eyebrow);
  font-weight: 500;
  letter-spacing: var(--ls-eyebrow);
  line-height: 1.4;
  text-transform: uppercase;
  color: var(--muted);
}

/* One step under .section-heading: a category on /kuhinje, the list of
   brands on /partneri. */
.gallery__group-title,
.brands__heading {
  font-size: clamp(19px, 17.247px + 0.449vw, 23px);   /* 19 -> 23 */
  font-weight: 500;
  line-height: 1.25;
  letter-spacing: -0.3px;
  text-wrap: balance;
}

/* Logotype — two lockups, picked in /admin (brand.logoStyle) and drawn by
   partials/logo.ejs. Shared: one colour (currentColor — ink on paper, paper
   in the mobile sheet), never wraps, sized by font-size alone. */
.logo {
  display: inline-flex;
  font-size: var(--fs-logo-name);
  line-height: 1;
  color: var(--ink);
  white-space: nowrap;
}

/* Horizontal (the default since November 2026): PUŽIN | STUDIO / KUHINJA.
   From the client-approved handoff; every size is in em of the name, so the
   lockup scales from font-size alone — 5.23em wide, 1em tall. */
.logo--horizontal {
  align-items: center;
  gap: 0.3em;
}
.logo--horizontal .logo__name {
  font-weight: 700;
  letter-spacing: -0.02em;
}
.logo--horizontal .logo__rule {
  flex: none;
  width: max(1px, 0.02em);
  height: 0.8em;
  background: currentColor;
}
.logo--horizontal .logo__tag {
  display: flex;
  flex-direction: column;
  gap: 0.32em;
  font-size: 0.27em;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.logo--horizontal .logo__tag-strong { font-weight: 700; }
.logo--horizontal .logo__tag-light { font-weight: 400; }

/* Stacked (the lockup until November 2026, kept to switch back to): the
   previous .logo rules, unchanged, scoped to .logo--stacked.

   After Häcker's "Häcker / kitchen.germanMade.": the name (brand.bold,
   exactly as typed) over a small uppercase tag (brand.regular) that runs
   exactly as wide as the name, both in the one ink colour. Either half may
   be missing; nothing is pinned to a fixed size.

   The width match is pure CSS. The lockup is an inline-flex column, as wide
   as its widest child. The name keeps its own width (align-self); the tag
   stretches to the column and spreads its letters — one span each, see
   partials/logo.ejs — with space-between. That is exact for any text and
   whichever font has loaded. The column-gap is the tag's minimum tracking:
   should a very short name leave the tag the wider of the two, the lockup
   simply grows to the tag and nothing overflows.

   Optical finish, from Schibsted Grotesk's own metrics, all in em so it
   scales with the name:
   - the tag's inline padding makes up the difference in side bearings
     (P and N/n of the bold name against S and A of the small tag), so the
     INK edges of the two lines meet, not just their boxes;
   - at line-height 1 the cap top sits 0.156em under the top of the line
     box and the baseline 0.141em above its bottom. Trimming both lines to
     cap top .. baseline lets the header centre the letters themselves; the
     name's untrimmed 0.141em under its baseline is the gap to the tag —
     tight, like the reference. Accents (the caron of Ž) hang above. */
.logo--stacked {
  flex-direction: column;
  align-items: stretch;
}
.logo--stacked .logo__name { align-self: flex-start; margin-top: -0.156em; font-weight: 700; }
.logo--stacked .logo__name:last-child { margin-bottom: -0.141em; }   /* no tag under it */
.logo--stacked .logo__tag {
  display: flex;
  justify-content: space-between;
  column-gap: 0.08em;
  margin-block: -0.156em -0.141em;
  padding-inline: 0.24em;
  font-size: 0.26em;
  font-weight: 500;
  text-transform: uppercase;
}
.logo--stacked .logo__space { white-space: pre; }

/* Where the browser can trim text boxes itself, it trims to the baseline it
   actually laid out. The em values above are exact for the font's design
   metrics, but browsers round ascent and descent to whole pixels, which can
   leave the letters up to a pixel off centre at some sizes. Same geometry:
   both lines cap top .. baseline, 0.141em of the name between them.
   Each line's baseline is also snapped to the pixel grid on its own, so the
   gap could still jump by a pixel with the lockup's position. Rounding the
   baseline-to-baseline distance — 0.141em of the name plus the tag's cap
   height, i.e. 1.2454em of the tag — to whole pixels makes both lines snap
   alike. (Every browser with text-box has round().) */
@supports (text-box: trim-both cap alphabetic) {
  .logo--stacked .logo__name,
  .logo--stacked .logo__name:last-child,
  .logo--stacked .logo__tag { margin-block: 0; }
  .logo--stacked .logo__name,
  .logo--stacked .logo__tag > span { text-box: trim-both cap alphabetic; }
  .logo--stacked .logo__tag { margin-top: calc(round(1.2454em, 1px) - 0.7031em); }
}

/* The logotype is a link to the home page on every page, including home. */
.logo--link { transition: opacity var(--transition); }
.logo--link:hover { opacity: .85; }

/* buttons ------------------------------------------------------------------ */

.btn {
  display: block;
  width: 100%;
  text-align: center;
  font-size: var(--fs-btn);
  font-weight: 500;
  line-height: 1.2;
  border-radius: var(--radius-pill);
  transition: background-color var(--transition), color var(--transition), opacity var(--transition);
}

.btn--primary {
  background: var(--ink);
  color: var(--paper);
  padding: 15px;
}
.btn--primary:hover { background: var(--ink-hover); }

.btn--secondary {
  color: var(--ink);
  padding: 13px;
  border: 1px solid var(--rule-strong);
}
.btn--secondary:hover { background: var(--paper-tinted); }

.btn--block { width: 100%; }

@media (min-width: 640px) {
  .btn--primary { display: inline-block; width: auto; padding: 14px 26px; }
  .btn--wide { padding: 15px 30px; }
  /* above the phone breakpoint the secondary reverts to a plain text link */
  .btn--secondary {
    display: inline-block;
    width: auto;
    padding: 14px 6px;
    border: 0;
    border-radius: 0;
  }
  .btn--secondary:hover { background: none; opacity: .85; }
}

/* ========================================================= header / nav == */

.site-header { border-bottom: var(--hairline); }

/* An exact height instead of padding around whatever the row holds: the
   hero below is sized as "the screen minus --header-h minus the hairline",
   so on landscape screens the header and the hero media together are
   exactly one screen. */
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  height: var(--header-h);
}

.site-nav,
.header-cta { display: none; }

.site-nav__list {
  display: flex;
  align-items: center;
  gap: var(--nav-gap);
}

.site-nav__link {
  font-size: var(--fs-nav);
  line-height: 1.4;
  color: var(--text-secondary);
  white-space: nowrap;
  transition: opacity var(--transition), color var(--transition);
}
.site-nav__link:hover { opacity: .85; }

/* The page you are on: ink instead of secondary. Nothing else changes —
   no underline, no weight shift; the colour step is the whole signal. */
.site-nav__link--active { color: var(--ink); }

.header-cta {
  font-size: 13px;
  font-weight: 500;
  line-height: 1.4;
  color: var(--ink);
  border-bottom: 1px solid var(--ink);
  padding-bottom: 2px;
  transition: opacity var(--transition);
}
.header-cta:hover { opacity: .85; }

/* hamburger: 22 / 22 / 14 bars, 1.5px high, 4px apart, >=44x44 hit area ---- */

.nav-toggle {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: center;
  gap: 4px;
  width: 44px;
  padding: 12px 0;
  flex: none;
}

/* extends the tap target vertically without changing the header's height */
.nav-toggle::before {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 44px;
  transform: translateY(-50%);
}

.nav-toggle__bar {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--ink);
}
.nav-toggle__bar:nth-child(3) { width: 14px; }

.nav-toggle--close { justify-content: center; height: 36.5px; }
.nav-toggle--close .nav-toggle__bar {
  position: absolute;
  right: 0;
  top: 50%;
  width: 22px;
  margin-top: -0.75px;
}
.nav-toggle--close .nav-toggle__bar:nth-child(1) { transform: rotate(45deg); }
.nav-toggle--close .nav-toggle__bar:nth-child(2) { transform: rotate(-45deg); }

/* The desktop row — logo, eight links, CTA — has its own breakpoint, 1024px,
   not the page's 900. The horizontal lockup (November 2026) is ~65px wider
   than the stacked one, and below ~970px the row no longer keeps 24px clear
   on either side of the nav, even at the tight rhythm below. Squeezing it in
   from 900 would have meant a smaller logo and the links packed at 14px
   apart; instead the header simply keeps the hamburger and the sheet up to
   1024px, so it is calm at every width, the logo always at its full size.
   (site.js closes an open sheet at the same width.) */
@media (min-width: 1024px) {
  .site-nav { display: block; }
  .header-cta { display: inline-block; }
  .nav-toggle { display: none; }
}

/* Eight nav links — and "Dnevni boravci" is a wide one — do not fit the
   designed 28px / 13.5px rhythm the moment the desktop header appears.
   Between 1024 and ~1120px the row tightens (20px gap, 13px links) instead
   of wrapping; above that it relaxes back to the designed values.
   Measured with the live labels and the horizontal lockup: at 1024px the
   nav keeps ~49px clear on either side, at 1120px ~56px. */
@media (min-width: 1024px) and (max-width: 1119.98px) {
  :root {
    --nav-gap: 20px;
    --fs-nav: 13px;
  }
}

/* ============================================================ mobile menu = */

/* The sheet is ink, not paper: on a phone it has to read as a layer that
   covers the page rather than as more page. Everything inside it therefore
   flips — hairlines to a translucent white, links to paper, the CTA to an
   inverted pill — and the focus ring goes paper too, because ink-on-ink is
   invisible. Nothing here applies at >=1024px, where the sheet does not exist. */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  flex-direction: column;
  background: var(--ink);
  color: var(--paper);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.mobile-menu[hidden] { display: none; }

/* the one hairline colour the dark sheet uses, everywhere */
.mobile-menu__bar,
.mobile-menu__list li { border-bottom: 1px solid rgba(255, 255, 255, .14); }

/* The header's row exactly: --header-h of content plus the 1px rule under
   it (border-box), so the close button lands where the hamburger was. */
.mobile-menu__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  height: calc(var(--header-h) + 1px);
  padding-inline: var(--gutter);
  flex: none;
}

/* the whole lockup, tag included, goes paper — one colour, as on paper */
.mobile-menu .logo { color: var(--paper); }
.mobile-menu .nav-toggle__bar { background: var(--paper); }

.mobile-menu a:focus-visible,
.mobile-menu button:focus-visible { outline-color: var(--paper); }

/* inverted CTA: paper pill, ink label */
.mobile-menu .btn--primary { background: var(--paper); color: var(--ink); }
.mobile-menu .btn--primary:hover { background: var(--paper); opacity: .88; }

/* flex: none — with eight links plus the CTA the sheet can be taller than
   a short phone screen. The three blocks must keep their intrinsic height
   and let the sheet scroll (overflow-y above) rather than be squashed. */
.mobile-menu__nav {
  padding-inline: var(--gutter);
  flex: none;
}

.mobile-menu__list li:last-child { border-bottom: 0; }

.mobile-menu__link {
  display: block;
  padding: 18px 0;
  font-size: 20px;
  font-weight: 400;
  line-height: 1.3;
  color: var(--paper);
  transition: opacity var(--transition);
}
.mobile-menu__link:hover { opacity: .85; }
.mobile-menu__link--active { font-weight: 500; }

.mobile-menu__foot {
  margin-top: auto;
  padding: 24px var(--gutter) calc(24px + env(safe-area-inset-bottom, 0px));
  flex: none;
}

@media (min-width: 1024px) {
  .mobile-menu { display: none !important; }
}

/* ==================================================================== hero */

/* After Häcker: the photo or video first, full-bleed, then the intro
   centred under it — the same centred column the closing CTA uses.

   On landscape screens header + media are exactly one screen: the media is
   the viewport minus --header-h minus the header's 1px hairline. svh (vh is
   the fallback) keeps that box still while a phone's toolbar slides in and
   out, and min-height stops a landscape phone squashing it into a strip.
   No radius — it runs edge to edge. The tint shows until the photo lands. */
.hero__media {
  width: 100%;
  height: calc(100vh - var(--header-h) - 1px);
  height: calc(100svh - var(--header-h) - 1px);
  min-height: 320px;
  overflow: hidden;
  background: var(--paper-tinted);
}

/* Upright screens (phones, tablets held in portrait) get a photo-shaped
   box instead of the whole screen. The client's photos are wide landscape
   shots (1.6–2.7 : 1), and a full-height box on a phone showed only the
   middle third of the kitchen. 3:2 — the shape the category galleries use —
   shows ~90% of the current hero photo and lets the headline land on the
   first screen. Landscape screens keep the full-screen hero above. */
@media (orientation: portrait) {
  .hero__media {
    height: auto;
    min-height: 0;
    aspect-ratio: 3 / 2;
  }
}

/* Photo or video, whichever is rendered, fills that box the same way, so
   nothing can shift between the two. */
.hero__photo,
.hero__video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* Only rendered alongside a video, and only shown when motion is unwelcome
   — or, in the carousel, when the video could not play (.is-still). */
.hero__photo--fallback { display: none; }

@media (prefers-reduced-motion: reduce) {
  .hero__video { display: none; }
  .hero__photo--fallback { display: block; }
}

/* ------------------------------------------------------- hero carousel -- */

/* Two or more slides (index.ejs, site.js): stacked in the same box, the one
   on screen .is-active. A new slide fades in OVER the old one, which keeps
   full opacity (.is-leaving) until the fade is over — so the box never shows
   its grey tint mid-fade. Without JavaScript slide 1 is simply the photo.

   touch-action: vertical scrolling and pinch-zoom stay with the browser,
   a sideways drag comes to site.js as a swipe (pan-y alone where the
   pinch-zoom keyword is unknown). isolation keeps the slides' z-indexes
   inside the box. */
.hero__media[data-hero-carousel] {
  position: relative;
  isolation: isolate;
  touch-action: pan-y;
  touch-action: pan-y pinch-zoom;
}

.hero__slides,
.hero__slide {
  position: absolute;
  inset: 0;
}

.hero__slide { opacity: 0; }
.hero__slide.is-active { z-index: 2; opacity: 1; }
.hero__slide.is-leaving { z-index: 1; opacity: 1; }

/* A video that could not play stands in as its photo. */
.hero__slide.is-still > .hero__video { display: none; }
.hero__slide.is-still > .hero__photo--fallback { display: block; }

/* Only the incoming slide is transitioned; 1.2s is FADE in site.js. The
   zoom runs for a photo's whole time on screen — its 6s plus the next
   slide's fade over it (--hero-zoom, set by site.js) — and holds its last
   frame, so nothing jumps when the slide leaves. */
@media (prefers-reduced-motion: no-preference) {
  .hero__slide.is-active { transition: opacity 1.2s ease-in-out; }

  .hero__slide.is-zooming > .hero__photo,
  .hero__slide.is-zooming > .hero__video {
    animation: hero-zoom var(--hero-zoom, 7200ms) linear both;
  }
}

@keyframes hero-zoom {
  from { transform: none; }
  to   { transform: scale(1.05); }
}

/* The controls: a small paper pill on the photo's bottom-left corner, its
   left edge on the content column (the .wrap gutter, centred past --maxw).
   Ink on paper reads on the whitest kitchen and on the darkest one alike.
   Inside, a pause/play toggle drawn in CSS and one 2px rule per slide; the
   active rule fills in ink over the photo's time (solid for a video).
   `hidden` in the markup until site.js has started. */
.hero__controls {
  position: absolute;
  z-index: 3;
  left: calc(max(0px, (100% - var(--maxw)) / 2) + var(--gutter));
  bottom: clamp(12px, 4.989px + 1.798vw, 28px);   /* 12 -> 28 */
  display: flex;
  align-items: center;
  padding: 2px 8px 2px 4px;
  background: var(--paper);
  border-radius: var(--radius-pill);
}
.hero__controls[hidden] { display: none; }

/* 28px tall hit areas (WCAG 2.5.8 asks for 24); the focus ring is drawn
   inside the button, where it is ink on paper rather than ink on a photo. */
.hero__toggle,
.hero__pick {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 28px;
  border-radius: var(--radius-pill);
  transition: opacity var(--transition);
}
.hero__toggle { width: 28px; }
.hero__pick { width: 24px; }

.hero__toggle:focus-visible,
.hero__pick:focus-visible { outline-offset: -2px; }

.hero__toggle:hover { opacity: .7; }

/* pause: two 2px bars ... */
.hero__toggle-icon {
  display: block;
  width: 7px;
  height: 10px;
  border-left: 2px solid var(--ink);
  border-right: 2px solid var(--ink);
}

/* ... play: a triangle, nudged right to sit optically centred */
.hero__media.is-stopped .hero__toggle-icon {
  width: 0;
  height: 0;
  margin-left: 2px;
  border-style: solid;
  border-width: 5px 0 5px 9px;
  border-color: transparent transparent transparent var(--ink);
}

.hero__line {
  position: relative;
  display: block;
  width: 16px;
  height: 2px;
  overflow: hidden;
  background: var(--rule-strong);
  transition: background-color var(--transition);
}

/* The slide on screen has a darker track, so it is marked even before its
   line starts to fill — after a pick while stopped, the fill sits at 0. */
.hero__pick:hover .hero__line,
.hero__pick[aria-current="true"] .hero__line { background: var(--muted); }

.hero__line::after {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: left center;
}

/* the slide on screen: solid — a video, or no motion wanted ... */
.hero__pick[aria-current="true"] .hero__line::after { transform: none; }

/* ... or filling over a photo's time (--hero-interval, set by site.js) */
@media (prefers-reduced-motion: no-preference) {
  .hero__pick.is-timed .hero__line::after {
    animation: hero-progress var(--hero-interval, 6000ms) linear both;
  }
}

@keyframes hero-progress {
  from { transform: scaleX(0); }
  to   { transform: none; }
}

/* Held (the toggle, the pointer on the controls, keyboard focus in them,
   a hidden tab, the hero out of view): zoom and line freeze where they are. */
.hero__media.is-paused .hero__slide > *,
.hero__media.is-paused .hero__line::after { animation-play-state: paused; }

.hero__intro {
  padding-block: var(--pad-hero-intro);
  text-align: center;
}

.hero__intro .eyebrow { margin-bottom: clamp(14px, 11.37px + 0.674vw, 20px); }

.hero__title {
  max-width: 20ch;
  margin: 0 auto clamp(16px, 13.37px + 0.674vw, 22px);
  font-size: var(--fs-h1);
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: var(--ls-h1);
  text-wrap: balance;
}

.hero__body {
  max-width: 52ch;
  margin: 0 auto clamp(24px, 19.62px + 1.124vw, 34px);
  font-size: var(--fs-hero-body);
  line-height: 1.65;
  color: var(--text-secondary);
  text-wrap: balance;
}

/* phone: the full-width stacked pills; from 640px a centred row */
.hero__actions {
  display: flex;
  flex-direction: column;
  gap: clamp(10px, 8.25px + 0.449vw, 14px);
}

@media (min-width: 640px) {
  .hero__actions {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
  }
}

@media (min-width: 900px) {
  .hero__title { line-height: 1.06; }
}

/* ===================================================================== usp */

/* Phone: an inset list, hairline above and between rows, none after the last.
   Tablet/desktop: a full-width hairline grid — top and bottom rules on the
   container, a left rule on every cell that is not in the first column,
   a bottom rule on every cell that is not in the last row. Never doubled. */

/* No top margin: the hero intro's bottom padding is the gap above the row. */
.usp__grid {
  margin: 0 var(--gutter);
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  border-top: var(--hairline);
}

.usp__item { padding: 18px 0; border-bottom: var(--hairline); }
.usp__item:last-child { border-bottom: 0; }

.usp__title {
  margin-bottom: clamp(5px, 3.69px + 0.337vw, 8px);
  font-size: var(--fs-usp-title);
  font-weight: 700;
  line-height: 1.3;
}

.usp__body {
  font-size: var(--fs-small);
  line-height: 1.55;
  color: var(--text-secondary);
}

@media (min-width: 640px) {
  .usp__grid {
    margin: 0 auto;
    max-width: var(--maxw);
    border-bottom: var(--hairline);
  }
  .usp__item {
    padding: clamp(22px, 14px + 1.25vw, 30px) clamp(20px, 8px + 1.875vw, 32px);
    border-bottom: 0;
  }
}

/* two columns: a left rule on the right-hand cell, a bottom rule on every
   cell that is not in the last row — the outer rules come from the grid. */
@media (min-width: 640px) and (max-width: 899.98px) {
  .usp__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .usp__item:nth-child(2n) { border-left: var(--hairline); }
  .usp__item:not(:nth-last-child(-n + 2)) { border-bottom: var(--hairline); }
}

@media (min-width: 900px) {
  .usp__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .usp__item + .usp__item { border-left: var(--hairline); }
}

/* ========================================================= page head (sub) */

/* Subpage opening block: eyebrow, H1, intro — the hero's text with the
   media, the buttons and the drama taken out. The bottom padding is
   deliberately 0: the section that follows brings its own 88/36px top
   padding, and stacking both would blow past the 72-100px rhythm. */

.page-head { padding-block: var(--pad-page-head) 0; }

.page-head__eyebrow { margin-bottom: clamp(14px, 11.37px + 0.674vw, 20px); }

.page-head__title {
  margin-bottom: clamp(16px, 13.37px + 0.674vw, 22px);
  font-size: var(--fs-h2-cta);          /* 28 -> 40, the CTA display size */
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: var(--ls-h2-cta);
  text-wrap: pretty;
}

.page-head__intro {
  max-width: 62ch;
  font-size: var(--fs-hero-body);
  line-height: 1.65;
  color: var(--text-secondary);
  text-wrap: pretty;
}

@media (min-width: 640px) {
  .page-head__title { line-height: 1.1; }
}

/* ========================================================= about / details */

/* One layout block, two uses: the landing's About + stats, and the
   category pages' details section (same collapse, no stats). */

.about,
.details { padding-block: var(--pad-about-top) var(--pad-about-bottom); }

.about__heading,
.details__heading {
  margin-bottom: 14px;
  font-size: var(--fs-h2);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: var(--ls-h2);
}

.about__text,
.details__text {
  margin-bottom: clamp(24px, 18.74px + 1.348vw, 36px);
  font-size: var(--fs-body);
  line-height: 1.7;
  color: var(--text-tertiary);
  text-wrap: pretty;
}

/* the last paragraph is flush with the section's own bottom padding */
.details__col > .details__text:last-child { margin-bottom: 0; }

.stats {
  display: flex;
  flex-wrap: wrap;
  gap: var(--gap-stats);
}

.stat__number {
  display: block;
  font-size: var(--fs-stat);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: var(--ls-stat);
}

.stat__label {
  display: block;
  margin-top: clamp(3px, 2.56px + 0.112vw, 4px);
  font-size: var(--fs-stat-label);
  letter-spacing: var(--ls-stat-label);
  line-height: 1.4;
  text-transform: uppercase;
  color: var(--muted);
}

@media (min-width: 900px) {
  .about__inner,
  .details__inner {
    display: grid;
    grid-template-columns: 1fr 1.3fr;
    gap: 64px;
    align-items: start;
  }
  .about__heading,
  .details__heading { margin-bottom: 0; line-height: 1.15; }
}

/* ================================================================= gallery */

.gallery { padding-bottom: var(--pad-about-bottom); }

.gallery__heading {
  margin-bottom: clamp(18px, 13.62px + 1.124vw, 28px);
}

/* /kuhinje: one block per category (the home page's "Naše kuhinje" tiles)
   — its title, a muted photo count, then its own grid. A hairline and the
   page-head rhythm set the blocks apart, so the long page reads as a few
   calm chapters rather than one wall of photos. */
.gallery__group + .gallery__group {
  margin-top: var(--pad-page-head);                     /* 40 -> 72 */
  padding-top: clamp(24px, 19.62px + 1.124vw, 34px);    /* 24 -> 34 */
  border-top: var(--hairline);
}

.gallery__group-count {
  margin: 2px 0 clamp(18px, 13.62px + 1.124vw, 28px);
  font-size: var(--fs-caption);
  line-height: 1.4;
  color: var(--muted);
}

/* Category pages: one photo per row on a phone, two from 640px up — at every
   width. Three columns made the work unreadable on a laptop, which is exactly
   what the client objected to. No fixed heights: a 3:2 box scales with the
   column, so the photos grow with the viewport instead of being capped. */
.gallery__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--gap-gallery);
}

.gallery__trigger {
  display: block;
  width: 100%;
  border-radius: var(--radius-photo);
}

.gallery__photo {
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: var(--radius-photo);
  background: var(--paper-tinted);
}

.gallery__caption {
  margin-top: clamp(7px, 5.69px + 0.337vw, 10px);
  font-size: var(--fs-caption);
  line-height: 1.4;
  color: var(--text-secondary);
}

/* "Cijela galerija" — the handoff's gallery link.
   Phone: a full-width outlined pill under the grid.
   Tablet/desktop: an underlined text link baseline-aligned with the H2. */

.gallery__link {
  display: block;
  margin-top: 18px;
  padding: 13px;
  text-align: center;
  font-size: var(--fs-small);
  font-weight: 500;
  line-height: 1.3;
  color: var(--ink);
  border: 1px solid var(--rule-strong);
  border-radius: var(--radius-pill);
  transition: background-color var(--transition), opacity var(--transition);
}
.gallery__link:hover { background: var(--paper-tinted); }

@media (min-width: 640px) {
  .gallery__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  /* Two rows: the heading and the link share the first one and sit on a
     common baseline; the grid of photos (or of tiles) spans the second. */
  .gallery__inner--with-link {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "head link"
      "grid grid";
    column-gap: 24px;
  }
  .gallery__inner--with-link .gallery__heading { grid-area: head; align-self: baseline; }
  .gallery__inner--with-link .gallery__grid,
  .gallery__inner--with-link .tiles { grid-area: grid; }
  .gallery__inner--with-link .gallery__link {
    grid-area: link;
    align-self: baseline;
    justify-self: end;
    margin-top: 0;
    padding: 0 0 2px;
    white-space: nowrap;
    border: 0;
    border-bottom: 1px solid var(--ink);
    border-radius: 0;
  }
  .gallery__inner--with-link .gallery__link:hover { background: none; opacity: .85; }
}

/* ============================================================ tiles (home) */

/* Two sibling sections on the home page, "Naše kuhinje" and "Ostali
   namještaj", both from partials/tile-section.ejs: same grid, same rhythm
   (each is a .gallery, so each brings the same bottom padding), no tonal
   fill to tell them apart. A tile is the button that opens its whole set of
   photos in the lightbox; the caption row under it names it, says how many
   photos are behind it and — when it stands for a category page — carries
   a separate link to that page: a real anchor, deliberately outside the
   button, because a link inside a button is neither valid nor operable by
   keyboard. */

.tiles {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--gap-gallery);
}

.tile {
  display: block;
  width: 100%;
  overflow: hidden;                 /* clips the hover scale */
  border-radius: var(--radius-photo);
  background: var(--paper-tinted);
}

.tile__photo {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform 300ms ease;
}
.tile:hover .tile__photo { transform: scale(1.03); }

@media (prefers-reduced-motion: reduce) {
  .tile:hover .tile__photo { transform: none; }
}

.tile__meta { margin-top: clamp(8px, 6.69px + 0.337vw, 11px); }

.tile__title {
  font-size: var(--fs-card-title);
  font-weight: 500;
  line-height: 1.3;
  color: var(--ink);
}

.tile__count {
  margin-top: 2px;
  font-size: var(--fs-caption);
  line-height: 1.4;
  color: var(--muted);
}

.tile__link {
  position: relative;
  display: inline-block;
  margin-top: 8px;
  padding-bottom: 2px;
  font-size: var(--fs-caption);
  font-weight: 500;
  line-height: 1.4;
  color: var(--ink);
  border-bottom: 1px solid var(--rule-strong);
  transition: opacity var(--transition), border-color var(--transition);
}
.tile__link:hover { border-bottom-color: var(--ink); opacity: .85; }

/* 44px tap target without 44px of layout: the same overlay trick as the
   hamburger. The overhang (~9px each way) stays inside the row gap, so it
   cannot steal a tap from the tile below. */
.tile__link::before {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 44px;
  transform: translateY(-50%);
}

@media (min-width: 900px) {
  .tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* ============================================================== partneri = */

/* /partneri: the partners sit right under the page head's intro — they
   belong to the h1 and have no heading of their own — and the appliance
   section (.brands) follows with the usual section rhythm. */

/* The partners (partials/partner-list.ejs): a ruled list, one partner per
   row — its logo and the client's text about it. Hairlines above, between
   and below the rows, across the full width like the brands' lattice
   further down; no cards. Phone: the logo over its text, both flush left.
   From 640px: two columns — a fixed one for the logos, so every text
   starts on the same line — with the logo centred on its text. */
.partners {
  margin-top: clamp(28px, 22.742px + 1.348vw, 40px);   /* 28 -> 40 */
  border-top: var(--hairline);
}

.partner {
  padding-block: clamp(24px, 18.742px + 1.348vw, 36px); /* 24 -> 36 */
  border-bottom: var(--hairline);
}

/* 44px tall at least, linked or not, so every row spaces the same */
.partner__mark {
  display: flex;
  align-items: center;
  min-height: 44px;
}

/* The featured makers, so a box about a third larger than the brands' —
   36px tall and at most 160px wide on a phone, 48 by 184 from 640px — on
   the same principle: about four times as wide as it is tall, so a compact
   mark is held by its height and a long wordmark by its width.
   object-position keeps a logo that does not fill the box flush left, on
   the text's edge. */
.partner__logo {
  width: auto;
  height: 36px;
  max-width: 160px;
  object-fit: contain;
  object-position: left center;
  mix-blend-mode: multiply;
}

/* no logo: the name in its place */
.partner__name {
  font-size: clamp(18px, 16.685px + 0.337vw, 21px);   /* 18 -> 21 */
  font-weight: 500;
  line-height: 1.3;
  color: var(--ink);
}

.partner__text {
  max-width: 60ch;
  margin-top: 14px;
  font-size: var(--fs-body);
  line-height: 1.7;
  color: var(--text-secondary);
  text-wrap: pretty;
}

/* The link is the logo (or the name) alone, not the row — the text is
   there to be read — and as tall as the mark, so at least 44px. Under the
   pointer the usual .85, set on the logo itself rather than the link so
   that multiply still blends it into the paper. */
.partner__link {
  display: flex;
  align-self: stretch;
  align-items: center;
}
.partner__logo,
.partner__name { transition: opacity var(--transition); }
.partner__link:hover .partner__logo,
.partner__link:hover .partner__name { opacity: .85; }

@media (min-width: 640px) {
  .partner {
    display: grid;
    grid-template-columns: 184px minmax(0, 1fr);
    align-items: center;
    column-gap: clamp(32px, 17.978px + 3.596vw, 64px);  /* 41 at 640 -> 64 */
  }
  .partner__logo { height: 48px; max-width: 184px; }
  .partner__text { margin-top: 0; }
}

.brands { padding-block: var(--pad-about-top) var(--pad-about-bottom); }

/* the section opens like the page head: kicker, heading, intro, body */
.brands__eyebrow { margin-bottom: clamp(14px, 11.37px + 0.674vw, 20px); }

.brands__title { margin-bottom: clamp(16px, 13.37px + 0.674vw, 22px); }

.brands__intro {
  max-width: 62ch;
  font-size: var(--fs-hero-body);
  line-height: 1.65;
  color: var(--text-secondary);
  text-wrap: pretty;
}

.brands__body {
  max-width: 70ch;
  font-size: var(--fs-body);
  line-height: 1.7;
  color: var(--text-tertiary);
  text-wrap: pretty;
}
.brands__intro + .brands__body { margin-top: clamp(16px, 13.37px + 0.674vw, 22px); }

/* the list's own heading, one step under the section's */
.brands__heading {
  margin: clamp(32px, 25.43px + 1.685vw, 47px) 0 clamp(18px, 13.62px + 1.124vw, 28px);   /* 32 -> 47 */
}

/* The brands' logo grid on /partneri (partials/logo-grid.ejs): the same
   continuous hairline lattice as the USP row, drawn a different way. The
   container paints the rule colour and a 1px grid gap lets it through, so
   every line exists exactly once at any column count — nothing can double,
   and there is no nth-child arithmetic to keep in sync with the
   breakpoints. The container's 1px block padding supplies the top and
   bottom rules; the outer left and right edges stay open, as in the USP
   row. The one thing this technique needs from the markup is a full last
   row — an unfilled tail would show the rule colour as a block — hence the
   `.brand--filler` tiles the template emits. */

.brands__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  padding-block: 1px;
  background: var(--rule);
}

.brand {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: clamp(72px, 61.48px + 2.697vw, 96px);   /* 72 -> 96 */
  padding: 12px 14px;
  text-align: center;
  background: var(--paper);
}

/* A brand with a url: the link is the whole cell — it takes over the
   cell's padding and fills it, so the click target is the cell and the
   cell is what turns --paper-tinted under the pointer (multiply blends the
   logo into the tint as into the paper). The lattice is untouched; the
   focus ring is drawn just inside the cell, along its hairlines. */
.brand--link { padding: 0; }

.brand__link {
  display: flex;
  flex: 1;
  align-self: stretch;
  align-items: center;
  justify-content: center;
  padding: 12px 14px;
  transition: background-color var(--transition);
}
.brand__link:hover { background: var(--paper-tinted); }
.brand__link:focus-visible { outline-offset: -2px; }

/* Every logo is fitted into the same box, about four times as wide as it
   is tall — 28px tall on a phone, 36px from 640px, at most 140px wide (and
   never wider than the cell allows) — so a compact mark (AEG, Beko) is held
   by its height and a long wordmark (Samsung, Blanco) by its width, and the
   two come out about equally heavy. In the brands' own colours (the
   client's choice, November 2026). multiply melts an uploaded JPG's white
   ground into the paper. */
.brand__logo {
  width: auto;
  height: 28px;
  max-width: 84%;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.brand__name {
  font-size: var(--fs-card-title);                    /* 15 -> 16 */
  font-weight: 500;
  line-height: 1.3;
  color: var(--ink);
}

/* Row-completing tiles: each is tagged with the column counts at which it
   is needed, and only those widths show it. */
.brand--filler { display: none; }

.brands__note {
  margin-top: 18px;
  font-size: var(--fs-caption);
  line-height: 1.5;
  color: var(--muted);
}

@media (max-width: 639.98px) {
  .brand--filler.is-2 { display: block; }
}

@media (min-width: 640px) {
  .brands__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .brand__logo { height: 36px; max-width: min(70%, 140px); }
}

@media (min-width: 640px) and (max-width: 899.98px) {
  .brand--filler.is-3 { display: block; }
}

@media (min-width: 900px) {
  .brands__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .brand--filler.is-4 { display: block; }
}

/* Fewer logos than columns (--n1 … --n3, set by the template): rather than
   fill the row with empty cells, the lattice shrinks to its items — each
   cell exactly as wide as in a full row, flush left under the text. */
@media (max-width: 639.98px) {
  .brands__grid--n1 { grid-template-columns: minmax(0, 1fr); width: calc((100% - 1px) / 2); }
}

@media (min-width: 640px) and (max-width: 899.98px) {
  .brands__grid--n1 { grid-template-columns: minmax(0, 1fr); width: calc((100% - 2px) / 3); }
  .brands__grid--n2 { grid-template-columns: repeat(2, minmax(0, 1fr)); width: calc((100% - 2px) / 3 * 2 + 1px); }
}

@media (min-width: 900px) {
  .brands__grid--n1 { grid-template-columns: minmax(0, 1fr); width: calc((100% - 3px) / 4); }
  .brands__grid--n2 { grid-template-columns: repeat(2, minmax(0, 1fr)); width: calc((100% - 3px) / 2 + 1px); }
  .brands__grid--n3 { grid-template-columns: repeat(3, minmax(0, 1fr)); width: calc((100% - 3px) / 4 * 3 + 2px); }
}

/* ================================================================= process */

/* The one tonal shift on the page. Full-bleed fill, content still capped. */
.process {
  background: var(--paper-tinted);
  padding-block: var(--pad-process);
}

.process__heading { margin-bottom: clamp(24px, 13.48px + 2.697vw, 48px); }

.process__list { display: grid; gap: 0; }

.step {
  display: flex;
  gap: 16px;
  margin-bottom: 20px;
}
.step:last-child { margin-bottom: 0; }

.step__number {
  flex: none;
  width: 24px;
  padding-top: 3px;
  font-size: var(--fs-step-number);
  font-weight: 700;
  letter-spacing: var(--ls-step-number);
  line-height: 1.4;
  color: var(--muted);
}

.step__title {
  margin-bottom: clamp(4px, 2.25px + 0.449vw, 8px);
  font-size: var(--fs-card-title);
  font-weight: 700;
  line-height: 1.3;
}

.step__body {
  font-size: var(--fs-small);
  line-height: 1.6;
  color: var(--text-secondary);
}

@media (min-width: 640px) {
  .process__list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 36px;
  }
  .step {
    display: block;
    margin-bottom: 0;
  }
  .step__number {
    width: auto;
    padding-top: 0;
    margin-bottom: 14px;
  }
}

@media (min-width: 900px) {
  .process__list { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* ================================================================= catalog */

/* Category pages only, and only once the client has uploaded a PDF. It reuses
   the process section's tonal treatment — full-bleed tint, same block padding
   — so the page keeps exactly one shift in ground colour before the CTA. */

.catalog {
  background: var(--paper-tinted);
  padding-block: var(--pad-process);
}

.catalog__eyebrow { margin-bottom: clamp(12px, 10.25px + 0.449vw, 16px); }

.catalog__heading {
  margin-bottom: clamp(10px, 8.69px + 0.337vw, 13px);
  font-size: var(--fs-h2);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: var(--ls-h2);
  text-wrap: balance;
}

.catalog__body {
  margin-bottom: clamp(20px, 15.62px + 1.124vw, 30px);
  max-width: 56ch;
  font-size: var(--fs-body);
  line-height: 1.7;
  color: var(--text-tertiary);
  text-wrap: pretty;
}

.catalog__actions {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: clamp(10px, 8.25px + 0.449vw, 14px);
}

/* the secondary route: view it in the browser instead of downloading */
.catalog__link {
  position: relative;
  align-self: center;
  padding-bottom: 2px;
  font-size: var(--fs-small);
  font-weight: 500;
  line-height: 1.3;
  color: var(--ink);
  border-bottom: 1px solid var(--rule-strong);
  transition: opacity var(--transition), border-color var(--transition);
}
.catalog__link:hover { border-bottom-color: var(--ink); opacity: .85; }

/* 44px tap target, drawn over the gap rather than inside the layout */
.catalog__link::before {
  content: '';
  position: absolute;
  left: -6px;
  right: -6px;
  top: 50%;
  height: 44px;
  transform: translateY(-50%);
}

@media (min-width: 640px) {
  .catalog__actions { flex-direction: row; align-items: center; flex-wrap: wrap; gap: 24px; }
  .catalog__link { align-self: auto; }
}

/* ============================================================= closing cta */

.closing {
  padding-block: var(--pad-closing);
  text-align: center;
}

.closing__heading {
  margin-bottom: clamp(12px, 10.25px + 0.449vw, 16px);
  font-size: var(--fs-h2-cta);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: var(--ls-h2-cta);
  text-wrap: balance;
}

.closing__body {
  margin-bottom: clamp(24px, 19.62px + 1.124vw, 34px);
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--text-secondary);
  text-wrap: pretty;
}

@media (min-width: 640px) {
  .closing__heading { line-height: 1.1; }
  .closing__body { max-width: 52ch; margin-inline: auto; line-height: 1.65; }
}

/* ================================================================== footer */

.site-footer {
  border-top: var(--hairline);
  padding-block: var(--pad-footer-top) var(--pad-footer-bottom);
  font-size: var(--fs-footer);
  line-height: 1.7;
  color: var(--text-secondary);
}

/* Phone: one block, no headings, reordered — address / contact / hours,
   joined by punctuation instead of line breaks. */
.footer__grid {
  display: flex;
  flex-direction: column;
}

.footer__brand { order: 0; margin-bottom: 14px; }
.footer__col--address { order: 1; }
.footer__col--contact { order: 2; }
.footer__col--hours { order: 3; }

.footer__heading { display: none; }
.footer__br { display: none; }
.footer__sep { display: inline; }

.footer__link { transition: opacity var(--transition); }
.footer__link:hover { opacity: .85; }

/* A WhatsApp number: the name it belongs to in ink, the number itself in
   the footer's secondary grey. */
.footer__phone-name {
  font-weight: 500;
  color: var(--ink);
}

/* Facebook / Instagram / WhatsApp under the logo: 20px glyphs in 44px hit
   areas. The row is pulled 12px left, so the first glyph's edge sits on the
   logo's, and 12px up into its own bottom padding, so the hit areas do not
   push the columns below further away. */
.footer__social {
  display: flex;
  margin: 6px 0 -12px -12px;
}

.footer__social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  color: var(--text-secondary);
  transition: color var(--transition);
}
.footer__social-link:hover { color: var(--ink); }

.footer__social-icon {
  display: block;
  width: 20px;
  height: 20px;
}

.footer__copyright {
  margin-top: clamp(20px, 11.24px + 2.247vw, 40px);
  font-size: var(--fs-copyright);
  line-height: 1.5;
  /* the AA-safe muted grey, not the design's lighter tint */
  color: var(--muted);
}

@media (min-width: 640px) {
  .footer__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px 32px;
  }
  .footer__brand,
  .footer__col--contact,
  .footer__col--address,
  .footer__col--hours { order: 0; margin-bottom: 0; }

  .footer__heading {
    display: block;
    margin-bottom: 10px;
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: 1.6px;
    line-height: 1.4;
    text-transform: uppercase;
    color: var(--muted);
  }
  .footer__br { display: inline; }
  .footer__sep { display: none; }

  /* The capitals of the first row line up: the headings' cap top sits 4.1px
     down (11.5px at line-height 1.4: 0.2em of leading + 0.156em above the
     caps). The stacked lockup is trimmed to its cap top (see .logo--stacked)
     and drops by those 4px. The horizontal one is not trimmed — its caps
     start 0.156em into its line box — so it moves by the difference, a pixel
     or so up. */
  .logo--stacked.logo--footer { margin-top: 4px; }
  .logo--horizontal.logo--footer { margin-top: calc(4.1px - 0.156em); }
}

@media (min-width: 900px) {
  .footer__grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; }
}

/* =============================================================== lightbox = */

/* The dialog itself fills the viewport and is transparent, so any click that
   lands outside the figure targets the dialog and closes it. */
.lightbox {
  --lb-chrome: 128px;               /* vertical room the bar + gap need */
  position: fixed;
  inset: 0;
  width: 100%;
  max-width: 100%;
  height: 100%;
  max-height: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--paper);
  overflow: hidden;
}

.lightbox[open] {
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox::backdrop { background: rgba(18, 18, 18, .94); }

/* The controls used to be arrows floating over the left and right edges,
   which cost the photo ~136px of width and still landed on top of it on a
   phone. They now sit in a bar UNDER the photo, so the image gets the full
   viewport width minus a 16px gutter and everything is thumb-reachable. */
.lightbox__figure {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  max-width: 100%;
  touch-action: pan-y;   /* without this the browser claims the horizontal drag and pointercancel kills the swipe */
}

.lightbox__img {
  max-width: calc(100vw - 32px);
  max-height: calc(100vh - var(--lb-chrome));
  max-height: calc(100dvh - var(--lb-chrome));   /* dvh where supported; vh above is the fallback */
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: var(--radius-photo);
}

/* The bar is the figure's caption: prev · (caption + counter) · next. */
.lightbox__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: min(1120px, calc(100vw - 32px));
}

.lightbox__meta {
  flex: 1 1 auto;
  min-width: 0;
  text-align: center;
}

.lightbox__caption {
  display: block;
  font-size: var(--fs-caption);
  line-height: 1.4;
  color: var(--rule-strong);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lightbox__counter {
  display: block;
  margin-top: 2px;
  font-size: var(--fs-caption);
  font-variant-numeric: tabular-nums;
  line-height: 1.4;
  color: var(--muted);
}

/* outlined pills, paper on dark, 44px minimum in both directions */
.lightbox__nav {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: none;
  min-height: 44px;
  padding: 10px 16px;
  font-size: var(--fs-small);
  font-weight: 500;
  line-height: 1.2;
  color: var(--paper);
  white-space: nowrap;
  border: 1px solid rgba(255, 255, 255, .34);
  border-radius: var(--radius-pill);
  transition: background-color var(--transition), border-color var(--transition);
}
.lightbox__nav:hover { background: rgba(255, 255, 255, .1); border-color: rgba(255, 255, 255, .6); }
.lightbox__nav[hidden] { display: none; }
.lightbox__chevron { font-size: 20px; line-height: 1; }

.lightbox__close {
  position: absolute;
  top: 8px;
  right: max(8px, calc(var(--gutter) - 12px));
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  font-size: 30px;
  line-height: 1;
  color: var(--paper);
  border-radius: var(--radius-pill);
  transition: opacity var(--transition);
}
.lightbox__close:hover { opacity: .7; }

/* ink is invisible on the near-black backdrop — paper ring instead */
.lightbox__nav:focus-visible,
.lightbox__close:focus-visible { outline-color: var(--paper); }

/* Phones: two labelled pills plus a caption do not fit one 358px row, so the
   bar wraps — caption and counter on top, the two buttons side by side under
   them, still at the bottom of the screen where a thumb is. The taller bar is
   paid for out of the image's height budget, hence --lb-chrome. */
@media (max-width: 479.98px) {
  .lightbox { --lb-chrome: 180px; }
  .lightbox__bar { flex-wrap: wrap; row-gap: 12px; }
  .lightbox__meta { order: -1; flex: 1 0 100%; }
  .lightbox__caption { white-space: normal; }
  .lightbox__nav { flex: 1 1 0; justify-content: center; padding: 10px 12px; }
}

/* ================================================== reduced motion escape = */

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