/* ORVIX demo kit — base.css
 *
 * Everything that repeats on every demo, driven entirely by tokens. A demo's own
 * style.css loads AFTER this file, sets the tokens and @font-face rules, and styles
 * its sections. Light or dark is only a token choice: nothing here assumes either.
 *
 * Tokens a demo is expected to override (defaults below are a neutral light theme):
 *   --paper --surface --surface-2   backgrounds, lightest to darkest step
 *   --ink --ink-soft --muted        text, strongest to weakest
 *   --line --line-strong            hairlines
 *   --accent --accent-deep --on-accent --accent-2
 *   --font-display --font-body
 *   --nav-break                      width where the burger gives way to inline links
 */

:root {
  --paper: #fafafa; --surface: #f1f1f1; --surface-2: #e6e6e6;
  --ink: #141414; --ink-soft: #4a4a4a; --muted: #7a7a7a;
  --line: rgba(20, 20, 20, .12); --line-strong: rgba(20, 20, 20, .26);
  --accent: #1d4ed8; --accent-deep: #1e3a8a; --on-accent: #fff; --accent-2: #c9b79f;
  --open: #1f8a5b; --closed: #b4563f;

  --font-display: Georgia, 'Times New Roman', serif;
  --font-body: system-ui, -apple-system, 'Segoe UI', sans-serif;

  --gutter: clamp(1.25rem, 5vw, 5rem);
  --container: 86rem;
  --nav-h: 5rem;
  --nav-break: 1180px;
  --section-y: clamp(4.5rem, 10vw, 10rem);
  --radius: 1.5rem;
  --ease: cubic-bezier(.22, 1, .36, 1);
}

/* The whole site is sized in rem, so very wide screens scale everything together. */
html { font-size: 16px; }
@media (min-width: 1920px) { html { font-size: 18px; } }
@media (min-width: 2560px) { html { font-size: 22px; } }
@media (min-width: 3400px) { html { font-size: 28px; } }

/* BASE */
*, *::before, *::after { box-sizing: border-box; }
/* Author display values (grid, flex) would otherwise beat the hidden attribute. */
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }
/* overflow-x: clip, never hidden: hidden turns body into a scroll container and breaks position: sticky. */
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--font-body); font-size: 1.0625rem; line-height: 1.65; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; overflow-x: clip; }
body.is-locked { overflow: hidden; }
h1, h2, h3, h4, p, ul, ol, dl, dd, figure, blockquote, table, fieldset { margin: 0; padding: 0; }
ul, ol { list-style: none; }
fieldset { border: 0; min-width: 0; }
img, svg, video, canvas { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
input, textarea, select { font: inherit; color: inherit; }
address { font-style: normal; }
em { font-style: normal; color: var(--accent); }
::selection { background: var(--accent); color: var(--on-accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 4px; }

/* UTILITIES */
.container { width: 100%; max-width: calc(var(--container) + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); }
.skip-link { position: fixed; top: .75rem; left: .75rem; z-index: 2000; padding: .75rem 1.25rem; border-radius: 999px; background: var(--ink); color: var(--paper); font-weight: 600; transform: translateY(-200%); transition: transform .3s var(--ease); }
.skip-link:focus { transform: none; }
.eyebrow { display: inline-flex; align-items: center; gap: .65rem; font-size: .78rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft); }
.dot { width: .45rem; height: .45rem; border-radius: 50%; background: var(--accent); flex: none; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-bottom: 1.1rem; margin-bottom: clamp(2rem, 4vw, 3.25rem); border-bottom: 1px solid var(--line); }
.section-head__index { font-size: .78rem; font-weight: 600; letter-spacing: .1em; color: var(--muted); }
.section-title { font-family: var(--font-display); font-weight: 400; font-size: clamp(2.25rem, 5vw, 4.75rem); line-height: 1.02; letter-spacing: -.03em; text-wrap: balance; }

/* PAGE HEAD: the short opening of a page of its own (kit/podstrana.html). Clears the fixed nav;
   a demo restyles it in style.css like any other section. */
.page-head { padding-block: calc(var(--nav-h) + clamp(1.5rem, 4vw, 3rem)) clamp(2rem, 5vw, 4rem); }
.page-head h1 { display: grid; gap: .75rem; }
.page-head__display { font-family: var(--font-display); font-weight: 400; font-size: clamp(2.75rem, 7vw, 6rem); line-height: 1; letter-spacing: -.03em; text-wrap: balance; }
.page-head p { max-width: 38rem; margin-block: 1.25rem 1.5rem; color: var(--ink-soft); }
/* The moving line inside GSAP's mask. Its padding makes the translated box taller than the mask,
   so a line waiting below it is fully hidden. It must NOT clip: with overflow: hidden and only
   .14em below the line box it cut 3.5 to 5.8px off j and g in the hero during the intro, and about
   1px off every scroll-split heading for good (Literata, Biblioteka kod Milutina, 2026-09-24,
   pitfall 25). The mask below is the only clip. */
.split-line { padding-block: .2em .14em; margin-block: -.2em -.14em; }
/* The element that actually clips. GSAP wraps every line in its own `<div class="split-line-mask"
   style="overflow: clip">` sized to exactly one line box, so the padding on .split-line above is
   powerless: it enlarges the inner box, not the clipping rectangle. An overflow clip rectangle is
   the padding box, so the room has to be paid for here. The negative margins give it back to the
   layout, and .is-split-lines makes these masks grid items so the two cancel exactly (see below).
   More at the bottom than the top: measured on Lora at 72px, descenders reach .27em below the
   baseline while the clip box ended 1.4px past it, and carons cleared the top by 3.1px. */
.split-line-mask { padding-block: .18em .36em; margin-block: -.18em -.36em; }
/* Set on the element being split (Kit.splitLines and Kit.splitHeadings add it). Grid, because the
   negative margins above only cancel the padding when the masks are grid items: as plain blocks the
   two adjacent negative margins collapse to the larger one instead of summing, each line ends up
   .14em too tall, and the whole headline visibly snaps when revert() restores the natural flow.
   Measured on the Borkovačko sokače hero: 26.6px at 1440, 18.1px at 390. Reported by Nikola,
   2026-09-23. !important because a demo's own style.css loads after this file and almost always
   sets `display: block` on its headline (it is a span), which would otherwise win on source order
   and silently bring the snap back. */
.is-split-lines { display: grid !important; align-content: start; }
/* align-content: start because a split heading that is itself a grid item (a title column beside a
   taller text column) is stretched to the row's height, and a grid's default `normal` alignment then
   spreads the line rows over it: „Recepti iz naše kuće” on the Tabor demo gained 152px of gaps
   between its three lines at 1440 (pitfall 27). Packed at the top, the extra height stays empty. */
/* The top padding is not decoration: Serbian capitals carry carons and acutes (Š Č Ć Ž Đ)
   that rise above the ascender, and a mask flush with the cap height shears them off, so
   "Šta" renders as "Sta". Found on the Ramonda build, 2026-09-22. */
.stars { color: #d9a441; letter-spacing: .12em; }

/* BUTTONS */
.btn { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: .7rem; padding: 1.05rem 1.7rem; border-radius: 999px; isolation: isolate; overflow: hidden; font-weight: 600; font-size: 1rem; line-height: 1; white-space: nowrap; transition: color .4s var(--ease), border-color .4s var(--ease); will-change: transform; }
.btn svg { width: 1.15em; height: 1.15em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.btn::before { content: ''; position: absolute; inset: 0; z-index: -1; border-radius: inherit; transform: translateY(101%); transition: transform .5s var(--ease); }
.btn:hover::before { transform: none; }
.btn--accent { background: var(--accent); color: var(--on-accent); } .btn--accent::before { background: var(--ink); } .btn--accent:hover { color: var(--paper); }
.btn--ink { background: var(--ink); color: var(--paper); } .btn--ink::before { background: var(--accent); } .btn--ink:hover { color: var(--on-accent); }
.btn--ghost { border: 1px solid var(--line-strong); } .btn--ghost::before { background: var(--ink); } .btn--ghost:hover { color: var(--paper); border-color: var(--ink); }
.btn--small { padding: .8rem 1.25rem; font-size: .92rem; }
.btn--large { padding: 1.3rem 2.2rem; font-size: 1.1rem; }
.btn[disabled] { opacity: .6; pointer-events: none; }
.link { display: inline-flex; align-items: center; gap: .5rem; font-weight: 600; color: var(--accent); padding-bottom: .25rem; border-bottom: 1px solid currentColor; width: fit-content; }
.link svg { width: 1.1em; height: 1.1em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform .4s var(--ease); }
.link:hover svg { transform: translate(.2em, -.2em); }

/* LIVE OPEN/CLOSED STATE (Kit.openStatus) */
.status { display: inline-flex; align-items: center; gap: .65rem; font-size: .95rem; font-weight: 500; color: var(--ink-soft); }
.status i { width: .6rem; height: .6rem; border-radius: 50%; background: var(--muted); flex: none; }
.status.is-open { color: var(--open); } .status.is-open i { background: var(--open); animation: kit-pulse 2s ease-in-out infinite; }
.status.is-closed i { background: var(--closed); }
@keyframes kit-pulse { 0%, 100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--open) 55%, transparent); } 50% { box-shadow: 0 0 0 .45rem transparent; } }

/* INTRO OVERLAY, PROGRESS BAR */
.intro { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; background: var(--paper); }
.no-js .intro, .is-failsafe .intro, .is-loaded .intro { display: none; }
.progress-bar { position: fixed; inset: 0 0 auto 0; height: 2px; z-index: 200; pointer-events: none; }
.progress-bar span { display: block; height: 100%; background: var(--accent); transform: scaleX(0); transform-origin: 0 50%; }

/* WATERMARK: mandatory while the site is a proposal. Colours are fixed (ORVIX), not themed. */
.watermark { position: fixed; left: 1rem; bottom: 1rem; z-index: 300; display: inline-flex; align-items: center; gap: .55rem; padding: .55rem .95rem; border-radius: 999px; background: rgba(12, 16, 22, .9); color: #f4f6f8; font-family: system-ui, -apple-system, sans-serif; font-size: .75rem; letter-spacing: .02em; white-space: nowrap; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); box-shadow: 0 .5rem 1.5rem rgba(0, 0, 0, .28); transition: bottom .6s var(--ease); }
.watermark i { width: .45rem; height: .45rem; border-radius: 50%; background: #c6ff3d; }
.watermark b { font-weight: 600; }

/* NAV + MOBILE MENU */
.nav { position: fixed; inset: 0 0 auto 0; z-index: 110; height: var(--nav-h); transition: transform .6s var(--ease), background-color .4s, border-color .4s; border-bottom: 1px solid transparent; }
.nav.is-scrolled { background: var(--paper); background: color-mix(in srgb, var(--paper) 82%, transparent); -webkit-backdrop-filter: blur(16px) saturate(1.3); backdrop-filter: blur(16px) saturate(1.3); border-bottom-color: var(--line); }
.nav.is-hidden { transform: translateY(-101%); }
.nav__inner { height: 100%; max-width: calc(var(--container) + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); display: flex; align-items: center; gap: 2rem; }
.nav__links { display: none; margin-left: auto; gap: clamp(1.1rem, 2vw, 2.25rem); }
.nav__links a { position: relative; font-size: .92rem; font-weight: 500; color: var(--ink-soft); padding: .5rem 0; transition: color .3s; }
.nav__links a::after { content: ''; position: absolute; left: 0; right: 0; bottom: .2rem; height: 1px; background: var(--accent); transform: scaleX(0); transform-origin: 100% 50%; transition: transform .5s var(--ease); }
.nav__links a:hover, .nav__links a.is-active, .nav__links a[aria-current="page"] { color: var(--ink); }
.nav__links a:hover::after, .nav__links a.is-active::after, .nav__links a[aria-current="page"]::after { transform: scaleX(1); transform-origin: 0 50%; }
.nav__cta { display: none; }
.nav__burger { margin-left: auto; width: 3rem; height: 3rem; border-radius: 50%; border: 1px solid var(--line-strong); display: grid; place-content: center; gap: .4rem; }
.nav__burger span { display: block; width: 1.15rem; height: 1.5px; background: var(--ink); transition: transform .5s var(--ease); }
.nav__burger[aria-expanded="true"] span:first-child { transform: translateY(.24rem) rotate(45deg); }
.nav__burger[aria-expanded="true"] span:last-child { transform: translateY(-.24rem) rotate(-45deg); }
@media (min-width: 640px) { .nav__cta { display: inline-flex; margin-left: auto; } .nav__burger { margin-left: 0; } }
/* Keep in sync with --nav-break (custom properties cannot be used inside media queries). */
@media (min-width: 1180px) { .nav__links { display: flex; } .nav__cta { margin-left: 0; } .nav__burger { display: none; } }
/* Language switch on a site with a second language (scripts/new-lang.mjs puts it between the links
   and the call button): this page in the other language, at every width, since the header stays
   up while the phone menu is open. Over a dark hero, recolour it in style.css with the burger. */
.nav__lang { margin-left: auto; display: inline-grid; place-content: center; min-width: 3rem; height: 3rem; padding-inline: .85rem; border-radius: 999px; border: 1px solid var(--line-strong); font-size: .78rem; font-weight: 600; letter-spacing: .08em; color: var(--ink); transition: border-color .3s; }
.nav__lang:hover { border-color: currentColor; }
.nav__lang ~ .nav__cta, .nav__lang ~ .nav__burger { margin-left: 0; }
@media (max-width: 639.98px) { .nav__lang { margin-right: -1.25rem; } }
@media (min-width: 1180px) { .nav__lang { margin-left: 0; height: 2.5rem; min-width: 2.5rem; } }

/* Pure CSS open/close so the menu works even if GSAP never loads. */
.menu { position: fixed; inset: 0; z-index: 100; background: var(--surface); padding: calc(var(--nav-h) + 2rem) var(--gutter) 2rem; display: flex; flex-direction: column; justify-content: space-between; gap: 2rem; visibility: hidden; clip-path: inset(0 0 100% 0); overflow-y: auto; transition: clip-path .8s var(--ease), visibility 0s linear .8s; }
.menu.is-open { visibility: visible; clip-path: inset(0 0 0% 0); transition: clip-path .8s var(--ease), visibility 0s; }
.menu__links { display: grid; }
.menu__links a { display: flex; align-items: baseline; gap: 1rem; padding: .9rem 0; border-bottom: 1px solid var(--line); font-family: var(--font-display); font-size: clamp(1.8rem, 7.5vw, 2.75rem); letter-spacing: -.03em; line-height: 1.1; overflow: hidden; }
.menu__links a i { font-family: var(--font-body); font-style: normal; font-size: .72rem; font-weight: 600; letter-spacing: .1em; color: var(--accent); }
.menu__links a > * { transform: translateY(120%); transition: transform .9s var(--ease); }
.menu.is-open .menu__links a > * { transform: none; }
.menu.is-open .menu__links a:nth-child(1) > * { transition-delay: .15s; } .menu.is-open .menu__links a:nth-child(2) > * { transition-delay: .2s; }
.menu.is-open .menu__links a:nth-child(3) > * { transition-delay: .25s; } .menu.is-open .menu__links a:nth-child(4) > * { transition-delay: .3s; }
.menu.is-open .menu__links a:nth-child(5) > * { transition-delay: .35s; } .menu.is-open .menu__links a:nth-child(6) > * { transition-delay: .4s; }
.menu.is-open .menu__links a:nth-child(7) > * { transition-delay: .45s; }
.menu__foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem 2rem; font-size: .9rem; color: var(--ink-soft); }
.menu__foot a { font-weight: 600; color: var(--accent); }

/* MARQUEE (Kit.marquee): the track holds two identical .marquee__group blocks. */
.marquee { overflow: hidden; padding-block: clamp(1.25rem, 2.5vw, 2.25rem); border-block: 1px solid var(--line); background: var(--surface); }
.marquee__track { display: flex; width: max-content; will-change: transform; }
.marquee__group { display: flex; align-items: center; flex: none; }
.marquee__group span { font-family: var(--font-display); font-size: clamp(1.9rem, 4.4vw, 4.25rem); letter-spacing: -.03em; line-height: 1.15; white-space: nowrap; }
.marquee__group .is-outline { color: transparent; -webkit-text-stroke: 1px var(--line-strong); }
.marquee__group i { width: clamp(.45rem, .8vw, .8rem); aspect-ratio: 1; border-radius: 50%; background: var(--accent-2); margin-inline: clamp(1.1rem, 2.4vw, 2.5rem); flex: none; }
.no-js .marquee__track, .is-reduced .marquee__track { animation: kit-marquee 50s linear infinite; }
@keyframes kit-marquee { to { transform: translateX(-50%); } }

/* FACT ROW (Kit.counters): real, sourced numbers only. */
.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 2.25rem 1.5rem; }
@media (min-width: 900px) { .facts { grid-template-columns: repeat(4, 1fr); } }
/* column-reverse puts the number above its label, and flex-end packs both to the TOP of the grid cell.
   Without it they sit at the bottom, so a fact whose label takes one line has its number lower than
   the neighbours whose labels wrap (Biblioteka kod Milutina, 2026-09-24). */
.fact { display: flex; flex-direction: column-reverse; justify-content: flex-end; gap: .9rem; padding-top: 1.4rem; border-top: 1px solid var(--line-strong); }
.fact dt { font-size: .78rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); max-width: 13rem; }
.fact dd { font-family: var(--font-display); font-size: clamp(2.6rem, 5.4vw, 5.25rem); line-height: .95; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }

/* NOTE TO THE OWNER: replaces [TODO] holes. Removed at handover together with the watermark. */
.owner-note { padding: 1rem 1.2rem; border-radius: 1rem; border: 1px dashed var(--line-strong); background: var(--surface); background: color-mix(in srgb, var(--accent-2) 18%, transparent); font-size: .92rem; color: var(--ink-soft); }
.owner-note b { color: var(--ink); }

/* MAP ON CLICK (Kit.mapOnClick): a cover with the address until the visitor asks for the map. */
.map { position: relative; overflow: hidden; border-radius: var(--radius); border: 1px solid var(--line-strong); background: var(--surface-2); aspect-ratio: 4 / 3; }
@media (min-width: 900px) { .map { aspect-ratio: 2 / 1; } }
.map__cover { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 1rem; padding: 1.5rem; text-align: center; }
.map__pin { width: 2.75rem; height: 2.75rem; fill: var(--accent); }
.map__address { font-family: var(--font-display); font-size: clamp(1.4rem, 2.6vw, 2.2rem); line-height: 1.05; letter-spacing: -.03em; }
.map__note { font-size: .8rem; color: var(--muted); max-width: 22rem; }
.map iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.map.is-loaded .map__cover { display: none; }

/* CONTACT FORM (Kit.contactForm): sold sites only, markup in kit/forma.html. */
.form { display: grid; gap: 1.1rem; max-width: 36rem; }
.form__row { display: grid; gap: 1.1rem; }
@media (min-width: 640px) { .form__row { grid-template-columns: 1fr 1fr; } }
.form label { display: grid; gap: .45rem; font-size: .85rem; font-weight: 600; color: var(--ink-soft); }
.form input:not([type="checkbox"]), .form select, .form textarea { width: 100%; padding: .95rem 1.05rem; border: 1px solid var(--line-strong); border-radius: .9rem; background: var(--paper); font-size: 1rem; font-weight: 400; color: var(--ink); transition: border-color .3s var(--ease), box-shadow .3s var(--ease); }
.form textarea { min-height: 9rem; resize: vertical; }
.form input:focus, .form select:focus, .form textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent); }
.form__consent { display: grid !important; grid-template-columns: auto 1fr; align-items: start; gap: .7rem !important; font-weight: 400 !important; line-height: 1.45; }
.form__consent input { width: 1.15rem; height: 1.15rem; margin-top: .1rem; accent-color: var(--accent); }
.form__consent a { color: var(--accent); text-decoration: underline; text-underline-offset: .2em; }
.form__note { font-size: .85rem; color: var(--muted); }
/* Honeypot: off-screen, not display:none, so simple bots still fill it. */
.form__trap { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form__status { min-height: 1.5em; font-size: .95rem; font-weight: 500; color: var(--ink-soft); }
.form__status[data-kind="ok"] { color: var(--open); }
.form__status[data-kind="error"] { color: var(--closed); }
.form[data-state="sending"] { opacity: .7; pointer-events: none; }
.form .btn { justify-self: stretch; }
@media (min-width: 640px) { .form .btn { justify-self: start; } }

/* STICKY CALL BAR (Kit.callbar): phones only. */
.callbar { position: fixed; inset: auto .75rem calc(.75rem + env(safe-area-inset-bottom)) .75rem; z-index: 250; display: none; gap: .5rem; transform: translateY(160%); transition: transform .6s var(--ease); }
.callbar.is-visible { transform: none; }
.callbar a { display: flex; align-items: center; justify-content: center; gap: .6rem; min-height: 3.5rem; border-radius: 999px; font-weight: 600; box-shadow: 0 1rem 2.5rem -.5rem rgba(0, 0, 0, .4); }
.callbar__call { flex: 1; background: var(--accent); color: var(--on-accent); font-size: .98rem; }
.callbar__call svg { width: 1.2rem; height: 1.2rem; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.callbar__alt { padding-inline: 1.5rem; background: var(--ink); color: var(--paper); }
@media (max-width: 767px) {
  .callbar { display: flex; }
  .watermark { left: .75rem; bottom: calc(.75rem + env(safe-area-inset-bottom)); font-size: .66rem; padding: .4rem .75rem; }
  .has-callbar .watermark { bottom: calc(5rem + env(safe-area-inset-bottom)); }
  /* The watermark sits over the open menu: keep the menu's phone number clear of it (Danka Dental Art, 2026-10-01). */
  .menu { padding-bottom: calc(4rem + env(safe-area-inset-bottom)); }
}

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