/* ==========================================================================
   ProVar ZVV — Metalna hirurgija
   Mobile-first stylesheet. Bez build sistema.
   ========================================================================== */

/* Archivo (variabilni: wdth 62–125, wght 100–900), lokalno hostovan, latin + latin-ext.
   Licenca: SIL Open Font License 1.1 (assets/fonts/OFL.txt). */
@font-face {
  font-family: "Archivo";
  src: url("../assets/fonts/archivo-var.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
}

:root {
  --graphite: #1A1F24;
  --graphite-2: #232A31;
  --graphite-3: #2E363E;
  --steel: #E3E6E4;
  --plate: #EEF0EE;
  --steel-line: rgba(26, 31, 36, .14);
  --steel-line-2: rgba(26, 31, 36, .28);
  --ink: #1A1F24;
  --muted: #58626B;
  --on-dark: #E6EAEE;
  --on-dark-muted: #98A3AE;
  --dark-line: rgba(230, 234, 238, .12);
  --argon: #5B63F6;
  --argon-deep: #3E45D8;
  --arc: #EEF1FF;
  --straw: #E2C98E;
  --gold: #D4A24C;
  --bronze: #A8612E;
  --violet: #6B3A86;
  --blue: #2E5DA8;
  --tint: linear-gradient(90deg, #E7D3A0 0%, #D4A24C 20%, #A8612E 40%, #6B3A86 60%, #2E5DA8 80%, #8FA7C9 100%);

  --font: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --wrap: 1320px;
  --pad: clamp(20px, 5vw, 56px);
  --hdr: 68px;
  --ease: cubic-bezier(.2, .7, .1, 1);
  --ease-io: cubic-bezier(.7, 0, .2, 1);
  --fab: 56px;
  --fab-gap: 18px;
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--hdr) + 12px);
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--steel);
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg, canvas, video { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
h1, h2, h3, h4 { margin: 0; line-height: 1.05; font-weight: 700; }
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }
ul, ol.steps { margin: 0; padding: 0; list-style: none; }

::selection { background: var(--argon); color: #fff; }

:focus-visible {
  outline: 2px solid var(--argon);
  outline-offset: 3px;
  border-radius: 2px;
}

.skip {
  position: absolute; left: 12px; top: -60px; z-index: 200;
  background: var(--argon); color: #fff; padding: 10px 16px;
  transition: top .2s;
}
.skip:focus { top: 12px; }

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

.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* ---------- Type ---------- */
.display {
  font-stretch: 125%;
  font-weight: 800;
  letter-spacing: -.025em;
  line-height: .9;
}
.h2 {
  font-size: clamp(2rem, 6vw, 4.25rem);
  font-stretch: 115%;
  font-weight: 750;
  letter-spacing: -.02em;
  line-height: .98;
  text-wrap: balance;
}
.h3 {
  font-size: clamp(1.25rem, 2.4vw, 1.6rem);
  font-stretch: 108%;
  font-weight: 700;
  letter-spacing: -.01em;
}
.lead {
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  line-height: 1.55;
  max-width: 58ch;
  color: var(--muted);
}
.dark .lead { color: var(--on-dark-muted); }
.small { font-size: .875rem; }

/* ---------- Buttons ---------- */
.btn {
  --bg: var(--argon);
  --fg: #fff;
  position: relative;
  display: inline-flex; align-items: center; gap: .6em;
  min-height: 52px; padding: 0 24px;
  background: var(--bg); color: var(--fg);
  font-weight: 650; font-stretch: 105%;
  letter-spacing: .005em;
  border-radius: 2px;
  overflow: hidden;
  isolation: isolate;
  transition: color .35s var(--ease), background .35s var(--ease), transform .35s var(--ease);
  will-change: transform;
}
.btn::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: var(--graphite);
  transform: scaleX(0); transform-origin: right;
  transition: transform .5s var(--ease-io);
}
.btn:hover::before { transform: scaleX(1); transform-origin: left; }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn--ghost { --bg: transparent; --fg: currentColor; box-shadow: inset 0 0 0 1px currentColor; }
.btn--ghost::before { background: var(--argon); }
.btn--ghost:hover { color: #fff; box-shadow: inset 0 0 0 1px var(--argon); }
.dark .btn::before { background: var(--on-dark); }
.dark .btn:hover { color: var(--graphite); }
.dark .btn--ghost::before { background: var(--argon); }
.dark .btn--ghost:hover { color: #fff; }

.link {
  position: relative; font-weight: 600;
  background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1px no-repeat;
  padding-bottom: 2px;
  transition: background-size .45s var(--ease);
}
.link:hover { background-size: 0 1px; background-position: 100% 100%; }

/* ---------- Header ---------- */
.hdr {
  position: fixed; inset: 0 0 auto; z-index: 100;
  height: var(--hdr);
  color: var(--on-dark);
  transition: background .4s var(--ease), box-shadow .4s var(--ease), transform .45s var(--ease);
}
.hdr.is-scrolled {
  background: rgba(26, 31, 36, .86);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  backdrop-filter: blur(14px) saturate(140%);
  box-shadow: 0 1px 0 var(--dark-line);
}
.hdr.is-hidden { transform: translateY(-100%); }
.hdr__in {
  height: 100%;
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
}
.brand { display: inline-flex; align-items: center; gap: 12px; flex: none; }
.brand__mark { width: 36px; height: 36px; }
.brand__txt { display: flex; flex-direction: column; line-height: 1; }
.brand__name { font-stretch: 125%; font-weight: 800; font-size: 1.1rem; letter-spacing: -.01em; }
.brand__sub { font-size: .72rem; color: var(--on-dark-muted); margin-top: 4px; letter-spacing: .02em; }

.nav { display: none; }
.nav__list { display: flex; gap: 4px; }
.nav__link {
  position: relative; display: block;
  padding: 8px 14px; font-size: .95rem; font-weight: 550;
  color: var(--on-dark-muted);
  transition: color .3s;
}
.nav__link::after {
  content: ""; position: absolute; left: 14px; right: 14px; bottom: 2px; height: 2px;
  background: var(--tint);
  transform: scaleX(0); transform-origin: left;
  transition: transform .45s var(--ease);
}
.nav__link:hover, .nav__link[aria-current="page"] { color: var(--on-dark); }
.nav__link:hover::after, .nav__link[aria-current="page"]::after { transform: scaleX(1); }

.hdr__right { display: flex; align-items: center; gap: 10px; }
.hdr__cta { display: none; }
.hdr__phone { display: none; }

.burger {
  position: relative; width: 48px; height: 48px;
  display: grid; place-items: center;
  box-shadow: inset 0 0 0 1px var(--dark-line);
  border-radius: 2px;
}
.burger span {
  position: absolute; left: 13px; right: 13px; height: 2px; background: currentColor;
  transition: transform .45s var(--ease), opacity .3s;
}
.burger span:nth-child(1) { transform: translateY(-5px); }
.burger span:nth-child(2) { transform: translateY(5px); }
.menu-open .burger span:nth-child(1) { transform: rotate(45deg); }
.menu-open .burger span:nth-child(2) { transform: rotate(-45deg); }

.mnav {
  position: fixed; inset: 0; z-index: 90;
  background: var(--graphite);
  color: var(--on-dark);
  padding: calc(var(--hdr) + 24px) var(--pad) 32px;
  display: flex; flex-direction: column; justify-content: space-between;
  clip-path: inset(0 0 100% 0);
  transition: clip-path .7s var(--ease-io);
  visibility: hidden;
}
.menu-open .mnav { clip-path: inset(0 0 0 0); visibility: visible; }
.mnav__list li { overflow: hidden; border-bottom: 1px solid var(--dark-line); }
.mnav__list a {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 14px 0;
  font-size: clamp(1.8rem, 8vw, 2.6rem); font-stretch: 120%; font-weight: 750; letter-spacing: -.02em;
  transform: translateY(105%);
  transition: transform .7s var(--ease);
}
.mnav__list a small { font-size: .8rem; font-weight: 500; color: var(--on-dark-muted); font-stretch: 100%; letter-spacing: 0; }
.menu-open .mnav__list a { transform: none; }
.menu-open .mnav__list li:nth-child(2) a { transition-delay: .05s; }
.menu-open .mnav__list li:nth-child(3) a { transition-delay: .1s; }
.menu-open .mnav__list li:nth-child(4) a { transition-delay: .15s; }
.menu-open .mnav__list li:nth-child(5) a { transition-delay: .2s; }
.mnav__foot { display: grid; gap: 6px; color: var(--on-dark-muted); font-size: .95rem; }
.mnav__foot a { color: var(--on-dark); font-weight: 600; }
.menu-open { overflow: hidden; }

/* ---------- Scroll progress ---------- */
.progress {
  position: fixed; inset: 0 0 auto; height: 2px; z-index: 110;
  background: var(--tint);
  transform-origin: left; transform: scaleX(var(--p, 0));
  pointer-events: none;
}

/* ---------- Hero (home) ---------- */
.dark { background: var(--graphite); color: var(--on-dark); }

.hero {
  /* --fab-zone: pojas pri dnu ekrana u kom stoje FAB dugmad (asistent / nazad na vrh).
     --ctrl-h: visina kontrola slajdera. Oba ulaze u donji padding sadržaja
     da se kontrole, dugmad i FAB-ovi nikad ne preklope. */
  --fab-zone: calc(var(--fab-gap) + var(--fab));
  --ctrl-h: 40px;
  --ctrl-gap: 12px;    /* od linije FAB dugmadi do kontrola */
  --ctrl-clear: 14px;  /* od kontrola do sadržaja heroja */
  --hero-top: 16px;    /* vazduh ispod hedera */
  position: relative;
  height: 100vh;
  height: 100svh;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding-top: calc(var(--hdr) + var(--hero-top));
  overflow: hidden;
  isolation: isolate;
}
.hero__grid {
  position: absolute; inset: 0; z-index: -2;
  background-image:
    linear-gradient(var(--dark-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--dark-line) 1px, transparent 1px);
  background-size: 64px 64px;
  background-position: calc(50% + var(--gx, 0px)) calc(50% + var(--gy, 0px));
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 45%, #000 20%, transparent 80%);
          mask-image: radial-gradient(ellipse 80% 70% at 50% 45%, #000 20%, transparent 80%);
  opacity: .55;
}
.hero__canvas { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; }
.hero__in {
  position: relative;
  padding-bottom: calc(var(--fab-zone) + var(--ctrl-gap) + var(--ctrl-h) + var(--ctrl-clear));
}

/* ---------- Hero slajder (pozadinske fotografije) ----------
   Slojevi u heroju, od pozadine ka sadržaju:
   -4 fotografije, -3 zatamnjenje, -2 tehnička mreža, -1 canvas zavara, 0 sadržaj, 3 kontrole.
   .hero__media nema svoj z-index, pa slajdovi ostaju u stacking kontekstu .hero. */
.hero__media { position: absolute; inset: 0; pointer-events: none; }
.hslide {
  position: absolute; inset: 0; z-index: -4;
  opacity: 0;
  transition: opacity 1.2s var(--ease);
}
.hslide.is-active { opacity: 1; }
.hslide picture { display: block; position: absolute; inset: 0; }
.hslide img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: 50% 45%;
  transform: scale(1.08);
  /* hladan, prigušen ton da se fotografija uklopi u paletu */
  filter: saturate(.5) contrast(1.06) brightness(.78);
}
.hslide.is-kb img { animation: kenburns var(--kb, 7200ms) linear both; }
@keyframes kenburns { from { transform: scale(1.08); } to { transform: scale(1); } }
.hero__media.is-paused .hslide.is-kb img { animation-play-state: paused; }

.hero__shade {
  position: absolute; inset: 0; z-index: -3; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(26, 31, 36, .94) 0%, rgba(26, 31, 36, .8) 45%, rgba(26, 31, 36, .3) 100%),
    linear-gradient(180deg, rgba(26, 31, 36, .62) 0%, rgba(26, 31, 36, .22) 30%, rgba(26, 31, 36, .7) 78%, var(--graphite) 100%),
    linear-gradient(rgba(46, 93, 168, .16), rgba(46, 93, 168, .16));
}
.hero--media .hero__grid { opacity: .3; }

/* Kontrole slajdera — desno dole, uvek iznad linije FAB dugmadi */
.hero__ctrl {
  position: absolute; z-index: 3;
  bottom: calc(var(--fab-zone) + var(--ctrl-gap));
  right: max(var(--pad), calc((100% - var(--wrap)) / 2 + var(--pad)));
  height: var(--ctrl-h);
  display: flex; align-items: center; gap: 14px;
}
.hctr { margin: 0; font-size: .8rem; letter-spacing: .08em; color: var(--on-dark-muted); white-space: nowrap; }
.hctr b { color: var(--on-dark); font-weight: 650; }
.hbars { display: flex; gap: 6px; }
.hbar { position: relative; width: 34px; height: 3px; background: rgba(230, 234, 238, .2); overflow: hidden; }
.hbar i {
  position: absolute; inset: 0; background: var(--tint);
  transform-origin: left; transform: scaleX(var(--f, 0));
}
.hbtns { display: flex; gap: 6px; }
.hbtn {
  width: 40px; height: 40px; display: grid; place-items: center; border-radius: 2px;
  color: var(--on-dark-muted);
  background: rgba(26, 31, 36, .5);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  box-shadow: inset 0 0 0 1px var(--dark-line);
  transition: background .3s, color .3s, box-shadow .3s;
}
.hbtn:hover { background: var(--argon); color: #fff; box-shadow: none; }
.hbtn svg { width: 16px; height: 16px; }

/* Tanka traka sa podacima ispod heroja (kad .titleblock ne staje u hero) */
.titleband { background: var(--graphite); color: var(--on-dark); }
.titleband[hidden] { display: none; }
.titleband .titleblock { margin-top: 0; border-top: 0; }

.hero__kicker {
  display: flex; flex-wrap: wrap; gap: 8px 18px; align-items: center;
  font-size: .95rem; color: var(--on-dark-muted);
  margin-bottom: clamp(18px, 3vh, 28px);
}
.hero__kicker b { color: var(--on-dark); font-weight: 600; }
.pulse {
  width: 8px; height: 8px; border-radius: 50%; background: #54D38A; flex: none;
  box-shadow: 0 0 0 0 rgba(84, 211, 138, .6);
  animation: pulse 2.2s infinite;
}
.pulse.is-off { background: var(--gold); box-shadow: none; animation: none; }
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(84, 211, 138, 0); } 100% { box-shadow: 0 0 0 0 rgba(84, 211, 138, 0); } }

.hero__title {
  position: relative;
  font-size: clamp(3.1rem, 19.5vw, 11rem);                    /* rezerva za pregledače bez svh */
  font-size: clamp(2.6rem, min(19.5vw, 17.5svh), 11rem);      /* skalira i po širini i po visini */
  color: #C9D0D8;
}
.hero__title .ln { display: block; }
.hero__title::after {
  content: attr(data-text);
  position: absolute; inset: 0;
  white-space: pre-line;
  background: radial-gradient(circle at var(--ax, -20%) var(--ay, 120%), #FFFFFF 0, #E4E7FF 6%, #9EA6FF 16%, rgba(158, 166, 255, 0) 34%);
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
  opacity: var(--glow, 0);
  pointer-events: none;
}
.hero__seam { height: 34px; margin: 6px 0 clamp(18px, 3vh, 30px); }

.hero__row {
  display: grid; gap: 22px;
}
.hero__txt { font-size: clamp(.95rem, 1.5vw, 1.2rem); color: var(--on-dark-muted); max-width: 52ch; }
.hero__txt strong { color: var(--on-dark); font-weight: 600; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 10px; }

.titleblock {
  margin-top: clamp(28px, 5vh, 52px);
  display: grid; grid-template-columns: repeat(2, 1fr);
  border-top: 1px solid var(--dark-line);
}
.titleblock > div {
  padding: 14px 14px 14px 0;
  border-bottom: 1px solid var(--dark-line);
}
.titleblock > div:nth-child(odd) { border-right: 1px solid var(--dark-line); }
.titleblock > div:nth-child(even) { padding-left: 14px; }
.titleblock dt { font-size: .78rem; color: var(--on-dark-muted); margin-bottom: 4px; }
.titleblock dd { margin: 0; font-size: 1.05rem; font-weight: 650; font-stretch: 110%; }

.hero__hint {
  display: none;
  position: absolute; right: max(var(--pad), calc((100% - var(--wrap)) / 2 + var(--pad))); top: calc(var(--hdr) + 28px);
  font-size: .8rem; color: var(--on-dark-muted);
  align-items: center; gap: 10px;
}
.hero__hint i { width: 28px; height: 1px; background: currentColor; display: block; }

/* ---------- Page hero (subpages) ---------- */
.phero {
  position: relative; overflow: hidden; isolation: isolate;
  padding: calc(var(--hdr) + clamp(48px, 10vh, 110px)) 0 clamp(40px, 7vh, 72px);
}
.phero .hero__grid { opacity: .4; }

/* Fotografija u pozadini podstranice — isti jezik zatamnjenja kao na početnoj.
   Slika je viša od heroja (116 %) da parallaks pomeranje ne otkrije ivicu. */
.phero--media .hero__grid { opacity: .26; }
.phero__media { position: absolute; inset: 0; z-index: -4; overflow: hidden; pointer-events: none; }
.phero__media img {
  position: absolute; left: 0; top: -8%;
  width: 100%; height: 116%;
  object-fit: cover; object-position: 50% 42%;
  filter: saturate(.5) contrast(1.06) brightness(.76);
}
.phero__shade {
  position: absolute; inset: 0; z-index: -3; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(26, 31, 36, .95) 0%, rgba(26, 31, 36, .82) 42%, rgba(26, 31, 36, .3) 100%),
    linear-gradient(180deg, rgba(26, 31, 36, .6) 0%, rgba(26, 31, 36, .28) 34%, rgba(26, 31, 36, .78) 88%, var(--graphite) 100%),
    linear-gradient(rgba(46, 93, 168, .16), rgba(46, 93, 168, .16));
}

.crumbs { display: flex; gap: 10px; font-size: .85rem; color: var(--on-dark-muted); margin-bottom: 22px; }
.crumbs a:hover { color: var(--on-dark); }
.phero__title { font-size: clamp(2.6rem, 10vw, 7.5rem); color: var(--on-dark); }
.phero__title .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .08em; margin-bottom: -.08em; }
.phero__title .ch { display: inline-block; transform: translateY(110%); opacity: 0; }
.phero__title.is-in .ch { transform: none; opacity: 1; transition: transform .9s var(--ease), opacity .6s; }
.phero__line { display: block; overflow: hidden; padding-bottom: .06em; }
.phero__lead { margin-top: 24px; }
.phero__seam {
  margin-top: clamp(28px, 5vh, 48px);
  height: 3px; background: var(--tint);
  transform-origin: left; transform: scaleX(0);
  animation: seam 1.6s .35s var(--ease-io) forwards;
}
@keyframes seam { to { transform: scaleX(1); } }

/* ---------- Sections ---------- */
.sec { position: relative; padding: clamp(72px, 12vw, 150px) 0; }
.sec--tight { padding: clamp(56px, 8vw, 96px) 0; }
.sec__head {
  display: grid; gap: 18px;
  margin-bottom: clamp(36px, 6vw, 72px);
}
.sec__head .lead { margin: 0; }
.rule { height: 1px; background: var(--steel-line); }
.dark .rule { background: var(--dark-line); }

/* Dimension line — structural device showing a real measure */
.dim {
  display: flex; align-items: center; gap: 12px;
  font-size: .82rem; color: var(--muted);
}
.dark .dim { color: var(--on-dark-muted); }
.dim::before, .dim::after {
  content: ""; flex: 1; height: 1px; background: currentColor; opacity: .5;
}
.dim::before { max-width: 28px; }
.dim span { white-space: nowrap; }

/* ---------- Materials (periodic tiles) ---------- */
.mats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--steel-line); border: 1px solid var(--steel-line); }
.mat {
  --mx: 50%; --my: 50%; --heat: 0;
  position: relative; overflow: hidden;
  background: var(--plate);
  padding: 18px 16px 20px;
  min-height: 250px;
  display: flex; flex-direction: column;
  transition: background .5s var(--ease);
}
.mat::before {
  content: ""; position: absolute; inset: -1px; pointer-events: none;
  background: radial-gradient(260px circle at var(--mx) var(--my), rgba(255, 180, 71, .38), rgba(212, 162, 76, .18) 30%, rgba(107, 58, 134, .12) 55%, transparent 75%);
  opacity: var(--heat);
  transition: opacity .5s var(--ease);
}
.mat__top { display: flex; justify-content: space-between; font-size: .78rem; color: var(--muted); }
.mat__sym {
  position: relative;
  font-size: clamp(2.6rem, 8vw, 3.6rem); font-stretch: 125%; font-weight: 800; letter-spacing: -.03em;
  margin: 18px 0 6px; line-height: 1;
}
.mat__name { font-weight: 700; font-size: 1.05rem; }
.mat__melt { margin-top: 2px; font-size: .85rem; color: var(--muted); }
.mat__melt b { color: var(--ink); font-weight: 650; }
.mat__desc { position: relative; margin-top: auto; padding-top: 16px; font-size: .9rem; color: var(--muted); line-height: 1.5; }
.mat__bar { position: relative; height: 3px; margin-top: 14px; background: var(--steel-line); overflow: hidden; }
.mat__bar i { position: absolute; inset: 0; background: var(--tint); transform-origin: left; transform: scaleX(0); transition: transform 1.2s var(--ease); }
.is-in .mat__bar i { transform: scaleX(var(--w)); }

/* ---------- Processes ---------- */
.proc { display: grid; gap: 28px; }
.proc__tabs {
  display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none;
  margin-inline: calc(var(--pad) * -1); padding-inline: var(--pad);
  scroll-snap-type: x proximity;
}
.proc__tabs::-webkit-scrollbar { display: none; }
.proc__tab {
  flex: none; scroll-snap-align: start;
  padding: 12px 18px; min-height: 48px;
  box-shadow: inset 0 0 0 1px var(--dark-line);
  color: var(--on-dark-muted); font-weight: 650; font-stretch: 110%;
  border-radius: 2px;
  transition: color .3s, box-shadow .3s, background .3s;
}
.proc__tab:hover { color: var(--on-dark); }
.proc__tab[aria-selected="true"] { background: var(--argon); color: #fff; box-shadow: none; }
.proc__stage {
  position: relative;
  border: 1px solid var(--dark-line);
  background:
    linear-gradient(var(--dark-line) 1px, transparent 1px) 0 0 / 32px 32px,
    linear-gradient(90deg, var(--dark-line) 1px, transparent 1px) 0 0 / 32px 32px,
    var(--graphite-2);
  aspect-ratio: 4 / 3;
  overflow: hidden;
}
.proc__svg { width: 100%; height: 100%; }
.proc__panel[hidden] { display: none; }
.proc__panel h3 { margin-bottom: 12px; }
.proc__panel p { color: var(--on-dark-muted); }
.spec { margin-top: 22px; border-top: 1px solid var(--dark-line); }
.spec div { display: grid; grid-template-columns: 9.5em 1fr; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--dark-line); font-size: .95rem; }
.spec dt { color: var(--on-dark-muted); }
.spec dd { margin: 0; font-weight: 550; }

/* schematic states */
.proc__svg .g { opacity: 0; transition: opacity .5s; }
.proc__svg[data-mode="tig"] .g-arc, .proc__svg[data-mode="tig"] .g-gas, .proc__svg[data-mode="tig"] .g-rod, .proc__svg[data-mode="tig"] .g-bead,
.proc__svg[data-mode="mig"] .g-arc, .proc__svg[data-mode="mig"] .g-gas, .proc__svg[data-mode="mig"] .g-wire, .proc__svg[data-mode="mig"] .g-bead,
.proc__svg[data-mode="mag"] .g-arc, .proc__svg[data-mode="mag"] .g-gas, .proc__svg[data-mode="mag"] .g-wire, .proc__svg[data-mode="mag"] .g-bead, .proc__svg[data-mode="mag"] .g-spatter,
.proc__svg[data-mode="rel"] .g-arc, .proc__svg[data-mode="rel"] .g-stick, .proc__svg[data-mode="rel"] .g-bead, .proc__svg[data-mode="rel"] .g-slag, .proc__svg[data-mode="rel"] .g-spatter,
.proc__svg[data-mode="plazma"] .g-jet, .proc__svg[data-mode="plazma"] .g-kerf, .proc__svg[data-mode="plazma"] .g-drops,
.proc__svg[data-mode="gasno"] .g-flame, .proc__svg[data-mode="gasno"] .g-kerf, .proc__svg[data-mode="gasno"] .g-drops,
.proc__svg[data-mode="hart"] .g-flame, .proc__svg[data-mode="hart"] .g-rod, .proc__svg[data-mode="hart"] .g-braze { opacity: 1; }
.proc__svg .g-gun { opacity: 1; }
.proc__svg[data-mode="rel"] .g-gun { opacity: 0; }
.travel { animation: travel 3.6s linear infinite; }
@keyframes travel { from { transform: translateX(-190px); } 80%, 100% { transform: translateX(0); } }
.bead-grow { stroke-dasharray: 190; stroke-dashoffset: 190; animation: grow 3.6s linear infinite; }
.proc__svg .torch { transition: transform .8s var(--ease); }
.proc__svg[data-mode="plazma"] .torch, .proc__svg[data-mode="gasno"] .torch { transform: translate(0, -6px); }
.flick { animation: flick .12s steps(2) infinite; transform-origin: center; }
@keyframes flick { 50% { opacity: .75; } }
.gas-p { animation: gas 1.8s linear infinite; }
@keyframes gas { from { transform: translateY(-10px); opacity: .7; } to { transform: translateY(26px); opacity: 0; } }
@keyframes grow { 80%, 100% { stroke-dashoffset: 0; } }
.drop { animation: drop 1s linear infinite; }
@keyframes drop { from { transform: translateY(0); opacity: 1; } to { transform: translateY(60px); opacity: 0; } }
.spat { animation: spat .9s ease-out infinite; }
@keyframes spat { from { transform: translate(0, 0); opacity: 1; } to { transform: translate(var(--sx), var(--sy)); opacity: 0; } }

/* ---------- Services index ---------- */
.svc { border-top: 1px solid var(--steel-line); }
.svc__row {
  position: relative;
  display: grid; grid-template-columns: 1fr auto; gap: 6px 16px; align-items: center;
  padding: 22px 0;
  border-bottom: 1px solid var(--steel-line);
  overflow: hidden;
}
.svc__row::before {
  content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px;
  background: var(--tint); transform: scaleX(0); transform-origin: left;
  transition: transform .7s var(--ease);
}
.svc__row:hover::before { transform: scaleX(1); }
.svc__name {
  font-size: clamp(1.35rem, 3.6vw, 2.5rem); font-stretch: 112%; font-weight: 700; letter-spacing: -.015em; line-height: 1.1;
  transition: transform .6s var(--ease), color .3s;
}
.svc__row:hover .svc__name { transform: translateX(10px); color: var(--argon-deep); }
.svc__meta { grid-column: 1 / -1; font-size: .92rem; color: var(--muted); max-width: 60ch; }
.svc__go {
  width: 44px; height: 44px; display: grid; place-items: center;
  box-shadow: inset 0 0 0 1px var(--steel-line-2); border-radius: 50%;
  transition: background .35s, color .35s, transform .5s var(--ease), box-shadow .35s;
}
.svc__go svg { width: 18px; height: 18px; }
.svc__row:hover .svc__go { background: var(--argon); color: #fff; box-shadow: none; transform: rotate(-45deg); }

.hoverimg {
  position: fixed; left: 0; top: 0; z-index: 60; pointer-events: none;
  width: 300px; aspect-ratio: 4/3; overflow: hidden;
  opacity: 0; transform: translate(-50%, -50%) scale(.85);
  transition: opacity .35s, transform .45s var(--ease);
  background: var(--graphite-2);
  box-shadow: 0 30px 60px -20px rgba(26, 31, 36, .5);
}
.hoverimg.is-on { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.hoverimg img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- CNC feature ---------- */
.cnc { display: grid; gap: 32px; align-items: center; }
.cnc__canvas-wrap { position: relative; background: var(--plate); border: 1px solid var(--steel-line); }
.cnc__canvas-wrap canvas { width: 100%; height: auto; aspect-ratio: 4 / 3; }
.cnc__tag {
  position: absolute; left: 12px; bottom: 12px;
  background: rgba(238, 240, 238, .92); padding: 6px 10px; font-size: .8rem; font-weight: 600;
}
.price { display: flex; align-items: baseline; gap: 10px; margin: 20px 0 26px; }
.price b { font-size: clamp(2.2rem, 5vw, 3.2rem); font-stretch: 120%; font-weight: 800; letter-spacing: -.02em; line-height: 1; }
.price span { color: var(--muted); }
.ticks { display: grid; gap: 10px; margin: 0 0 28px; }
.ticks li { display: flex; gap: 12px; align-items: flex-start; }
.ticks li::before { content: ""; flex: none; width: 14px; height: 2px; margin-top: .72em; background: var(--argon); }

/* ---------- Generator (CNC page) ---------- */
.gen { display: grid; gap: 24px; }
.gen__stage { position: relative; background: #0F1316; border: 1px solid var(--dark-line); }
.gen__stage canvas { width: 100%; height: auto; aspect-ratio: 4 / 3; }
.gen__read {
  position: absolute; left: 0; right: 0; bottom: 0;
  display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  padding: 10px 14px; font-size: .82rem; color: var(--on-dark-muted);
  background: linear-gradient(transparent, rgba(15, 19, 22, .9));
}
.gen__read b { color: var(--on-dark); font-weight: 600; }
.gen__ctrl { display: grid; gap: 20px; align-content: start; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 10px 14px; min-height: 44px;
  box-shadow: inset 0 0 0 1px var(--dark-line); border-radius: 2px;
  color: var(--on-dark-muted); font-weight: 600; font-size: .92rem;
  transition: background .3s, color .3s, box-shadow .3s;
}
.chip:hover { color: var(--on-dark); }
.chip[aria-pressed="true"] { background: var(--argon); color: #fff; box-shadow: none; }
.field { display: grid; gap: 8px; }
.field label, .field .lbl { display: flex; justify-content: space-between; font-size: .88rem; color: var(--on-dark-muted); }
.field output { color: var(--on-dark); font-weight: 600; }
input[type="range"] {
  -webkit-appearance: none; appearance: none; width: 100%; height: 28px; background: transparent;
}
input[type="range"]::-webkit-slider-runnable-track { height: 2px; background: var(--dark-line); }
input[type="range"]::-moz-range-track { height: 2px; background: var(--dark-line); }
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 22px; height: 22px; margin-top: -10px;
  background: var(--argon); border: 3px solid var(--graphite); border-radius: 50%;
  box-shadow: 0 0 0 1px var(--argon);
}
input[type="range"]::-moz-range-thumb { width: 18px; height: 18px; background: var(--argon); border: 3px solid var(--graphite); border-radius: 50%; }
.gen__btns { display: flex; flex-wrap: wrap; gap: 10px; }

.calc { display: grid; gap: 14px; }
.calc__row { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; }
.inp {
  width: 100%; min-height: 52px; padding: 12px 14px;
  background: transparent; border: 0; border-radius: 2px;
  box-shadow: inset 0 0 0 1px var(--steel-line-2);
  transition: box-shadow .3s;
}
.inp:focus { outline: none; box-shadow: inset 0 0 0 2px var(--argon); }
.dark .inp { box-shadow: inset 0 0 0 1px var(--dark-line); }
.dark .inp:focus { box-shadow: inset 0 0 0 2px var(--argon); }
.calc__out { padding: 18px; background: var(--graphite-2); display: grid; gap: 4px; }
.calc__out b { font-size: clamp(1.8rem, 4vw, 2.4rem); font-stretch: 118%; font-weight: 800; letter-spacing: -.02em; }
.calc__out small { color: var(--on-dark-muted); }

/* ---------- Steps (real sequence) ---------- */
.steps { position: relative; display: grid; gap: 0; counter-reset: step; }
.steps__line {
  position: absolute; left: 19px; top: 8px; bottom: 8px; width: 2px;
  background: var(--steel-line);
}
.steps__line i { position: absolute; inset: 0; background: var(--tint); background-size: 100% 100%; transform-origin: top; transform: scaleY(var(--sp, 0)); background: linear-gradient(180deg, #E7D3A0, #D4A24C 25%, #A8612E 45%, #6B3A86 65%, #2E5DA8 85%); }
.step { position: relative; display: grid; grid-template-columns: 40px 1fr; gap: 18px; padding: 0 0 36px; }
.step:last-child { padding-bottom: 0; }
.step__n {
  position: relative; z-index: 1;
  width: 40px; height: 40px; display: grid; place-items: center;
  background: var(--steel); box-shadow: inset 0 0 0 1px var(--steel-line-2); border-radius: 50%;
  font-weight: 700; font-size: .9rem;
  transition: background .4s, color .4s, box-shadow .4s;
}
.step.is-lit .step__n { background: var(--graphite); color: #fff; box-shadow: 0 0 0 4px rgba(91, 99, 246, .18); }
.step h3 { margin: 6px 0 8px; }
.step p { color: var(--muted); max-width: 52ch; }

/* ---------- References rail ---------- */
.rail {
  display: grid; grid-auto-flow: column; grid-auto-columns: min(78vw, 360px); gap: 14px;
  overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: var(--pad);
  padding: 4px var(--pad) 20px; margin-inline: calc(var(--pad) * -1);
  scrollbar-width: none;
  cursor: grab;
}
.rail::-webkit-scrollbar { display: none; }
.rail.is-drag { cursor: grabbing; scroll-snap-type: none; }
.rail.is-drag a { pointer-events: none; }
.card { scroll-snap-align: start; display: flex; flex-direction: column; }
.card__img {
  position: relative; overflow: hidden; aspect-ratio: 4 / 5;
  background: var(--graphite-2) url("../assets/plate.svg") center / 60px;
}
.card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.1s var(--ease), filter .6s; filter: saturate(.85) contrast(1.05); }
.card:hover .card__img img { transform: scale(1.06); filter: saturate(1) contrast(1.05); }
.card__cat {
  position: absolute; left: 10px; top: 10px;
  background: rgba(26, 31, 36, .82); color: var(--on-dark);
  font-size: .76rem; padding: 5px 9px; font-weight: 600;
}
.card__body { padding: 14px 2px 0; }
.card__body h3 { font-size: 1.15rem; font-stretch: 108%; margin-bottom: 6px; }
.card__body p { font-size: .92rem; color: var(--muted); }
.dark .card__body p { color: var(--on-dark-muted); }
.rail__nav { display: flex; gap: 8px; }
.rbtn {
  width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%;
  box-shadow: inset 0 0 0 1px var(--steel-line-2);
  transition: background .3s, color .3s, box-shadow .3s;
}
.rbtn:hover { background: var(--graphite); color: #fff; box-shadow: none; }
.rbtn svg { width: 18px; height: 18px; }

/* ---------- About ---------- */
.about { display: grid; gap: 36px; }
.about__img { position: relative; aspect-ratio: 4/5; overflow: hidden; background: var(--graphite-2) url("../assets/plate.svg") center / 60px; }
.about__img img { width: 100%; height: 100%; object-fit: cover; }
.about__quote {
  font-size: clamp(1.4rem, 3.2vw, 2.3rem); font-stretch: 108%; font-weight: 600; line-height: 1.22; letter-spacing: -.012em;
  margin: 0 0 22px; text-wrap: pretty;
}
.about__sig { display: flex; align-items: center; gap: 14px; margin-bottom: 30px; }
.about__sig i { width: 36px; height: 2px; background: var(--tint); }
.about__sig b { display: block; }
.about__sig span { color: var(--muted); font-size: .9rem; }
.facts { display: grid; grid-template-columns: repeat(2, 1fr); border-top: 1px solid var(--steel-line); }
.fact { padding: 18px 12px 18px 0; border-bottom: 1px solid var(--steel-line); }
.fact:nth-child(odd) { border-right: 1px solid var(--steel-line); }
.fact:nth-child(even) { padding-left: 16px; }
.fact b { display: block; font-size: clamp(1.8rem, 4.5vw, 2.6rem); font-stretch: 120%; font-weight: 800; letter-spacing: -.02em; line-height: 1.05; }
.fact span { font-size: .88rem; color: var(--muted); }

/* ---------- Partners marquee ---------- */
.marquee { overflow: hidden; border-block: 1px solid var(--steel-line); padding: 22px 0; -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); }
.marquee__track { display: flex; width: max-content; animation: marq 38s linear infinite; }
.marquee:hover .marquee__track { animation-play-state: paused; }
.marquee__track a {
  display: inline-flex; align-items: center; gap: 28px; padding-right: 28px;
  font-size: clamp(1.3rem, 3vw, 2rem); font-stretch: 118%; font-weight: 700; letter-spacing: -.015em;
  color: var(--muted); white-space: nowrap; transition: color .3s;
}
.marquee__track a:hover { color: var(--ink); }
.marquee__track a::after { content: ""; width: 10px; height: 10px; border: 2px solid var(--gold); transform: rotate(45deg); }
@keyframes marq { to { transform: translateX(-50%); } }

/* ---------- CTA ---------- */
.cta { position: relative; overflow: hidden; isolation: isolate; }
.cta__big {
  display: block;
  font-size: clamp(2.6rem, 11vw, 9rem); font-stretch: 125%; font-weight: 800; letter-spacing: -.03em; line-height: .92;
  margin-bottom: 28px;
}
.cta__phone {
  display: inline-flex; flex-direction: column; gap: 4px;
  font-size: clamp(1.6rem, 5vw, 3.2rem); font-stretch: 115%; font-weight: 750; letter-spacing: -.01em;
  background: var(--tint) 0 100% / 0 3px no-repeat;
  padding-bottom: 6px;
  transition: background-size .8s var(--ease);
}
.cta__phone:hover { background-size: 100% 3px; }
.cta__row { display: grid; gap: 28px; margin-top: 40px; }
.cta__cards { display: grid; gap: 1px; background: var(--dark-line); border: 1px solid var(--dark-line); }
.cta__card { background: var(--graphite); padding: 18px; display: grid; gap: 4px; transition: background .3s; }
.cta__card:hover { background: var(--graphite-2); }
.cta__card span { font-size: .82rem; color: var(--on-dark-muted); }
.cta__card b { font-weight: 650; font-size: 1.05rem; word-break: break-word; }

/* ---------- Footer / title block ---------- */
.ftr { background: var(--graphite); color: var(--on-dark); padding: 56px 0 calc(28px + var(--fab) + var(--fab-gap)); border-top: 1px solid var(--dark-line); }
.ftr__top { display: grid; gap: 36px; margin-bottom: 44px; }
.ftr__brand p { color: var(--on-dark-muted); max-width: 40ch; margin-top: 16px; }
.ftr__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.ftr__h { font-size: .82rem; color: var(--on-dark-muted); margin-bottom: 12px; font-weight: 500; }
.ftr__cols li { margin-bottom: 8px; }
.ftr__cols a { color: var(--on-dark); transition: color .3s; }
.ftr__cols a:hover { color: var(--straw); }
.tb {
  display: grid; grid-template-columns: 1fr 1fr;
  border: 1px solid var(--dark-line);
  font-size: .85rem;
}
.tb > div { padding: 10px 12px; border-right: 1px solid var(--dark-line); border-bottom: 1px solid var(--dark-line); }
.tb > div:nth-child(2n) { border-right: 0; }
.tb span { display: block; color: var(--on-dark-muted); font-size: .74rem; margin-bottom: 2px; }
.tb b { font-weight: 600; }
.tb__wide { grid-column: 1 / -1; border-right: 0 !important; }
.ftr__bot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 22px; font-size: .82rem; color: var(--on-dark-muted); }
.ftr__bot a:hover { color: var(--on-dark); }
.social { display: flex; gap: 8px; margin-top: 20px; }
.social a {
  width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%;
  box-shadow: inset 0 0 0 1px var(--dark-line); transition: background .3s, box-shadow .3s;
}
.social a:hover { background: var(--argon); box-shadow: none; }
.social svg { width: 18px; height: 18px; }

/* ---------- Reveal ---------- */
[data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
[data-reveal].is-in { opacity: 1; transform: none; }
[data-cut] { position: relative; clip-path: inset(0 100% 0 0); transition: clip-path 1.2s var(--ease-io); }
[data-cut]::after {
  content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 2px; z-index: 2;
  background: #fff; box-shadow: 0 0 12px 3px rgba(158, 166, 255, .9), 0 0 30px 8px rgba(255, 179, 71, .45);
  opacity: 0;
}
[data-cut].is-in { clip-path: inset(0 0 0 0); }
[data-cut].is-in::after { animation: cutline 1.2s var(--ease-io) forwards; }
@keyframes cutline { 0% { left: 0; opacity: 1; } 90% { opacity: 1; } 100% { left: 100%; opacity: 0; } }

/* ---------- Cursor (desktop only) ---------- */
.cursor { display: none; }

/* ---------- FABs: assistant (left) + back to top (right) — same line ---------- */
.totop {
  position: fixed; right: var(--fab-gap); bottom: var(--fab-gap); z-index: 80;
  width: var(--fab); height: var(--fab); border-radius: 50%;
  display: grid; place-items: center;
  background: var(--graphite); color: #fff;
  box-shadow: 0 10px 30px -10px rgba(26, 31, 36, .6);
  opacity: 0; transform: translateY(20px) scale(.9); pointer-events: none;
  transition: opacity .4s, transform .5s var(--ease), background .3s;
}
.totop.is-on { opacity: 1; transform: none; pointer-events: auto; }
.totop:hover { background: var(--argon); }
.totop svg.ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.totop .ring circle { fill: none; stroke-width: 2.5; }
.totop .ring .bg { stroke: rgba(255, 255, 255, .14); }
.totop .ring .fg { stroke: var(--gold); stroke-linecap: round; stroke-dasharray: 163.4; stroke-dashoffset: calc(163.4 - 163.4 * var(--p, 0)); }
.totop .arr { width: 18px; height: 18px; transition: transform .4s var(--ease); }
.totop:hover .arr { transform: translateY(-3px); }

/* ---------- Lightbox ---------- */
.lb {
  position: fixed; inset: 0; z-index: 150;
  background: rgba(15, 19, 22, .94);
  display: grid; place-items: center; padding: 64px 12px;
  opacity: 0; visibility: hidden; transition: opacity .35s, visibility .35s;
}
.lb.is-open { opacity: 1; visibility: visible; }
.lb img { max-height: 80vh; width: auto; max-width: 100%; object-fit: contain; }
.lb__cap { color: var(--on-dark); margin-top: 14px; text-align: center; font-size: .95rem; }
.lb__btn {
  position: absolute; width: 48px; height: 48px; display: grid; place-items: center;
  color: #fff; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .2);
}
.lb__btn:hover { background: var(--argon); }
.lb__btn svg { width: 20px; height: 20px; }
.lb__close { top: 12px; right: 12px; }
.lb__prev { left: 12px; bottom: 12px; }
.lb__next { right: 12px; bottom: 12px; }

/* ---------- Filters / grid (reference page) ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 32px; }
.filters .chip { box-shadow: inset 0 0 0 1px var(--steel-line-2); color: var(--muted); }
.filters .chip:hover { color: var(--ink); }
.filters .chip[aria-pressed="true"] { color: #fff; box-shadow: none; }
.grid { display: grid; grid-template-columns: 1fr; gap: 36px 16px; }
.grid .card { transition: opacity .4s, transform .5s var(--ease); }
.grid .card.is-hidden { display: none; }
.grid .card__img { aspect-ratio: 4 / 3; }

/* ---------- Service detail (usluge page) ---------- */
.sdet { display: grid; gap: 28px; padding: clamp(48px, 8vw, 96px) 0; border-top: 1px solid var(--steel-line); }
.sdet__img { aspect-ratio: 4/3; overflow: hidden; background: var(--graphite-2) url("../assets/plate.svg") center / 60px; }
.sdet__img img { width: 100%; height: 100%; object-fit: cover; }
.sdet__txt h2 { margin-bottom: 16px; }
.sdet__txt p { color: var(--muted); max-width: 60ch; }
.sdet__list { margin-top: 20px; display: grid; gap: 0; border-top: 1px solid var(--steel-line); }
.sdet__list li { padding: 10px 0; border-bottom: 1px solid var(--steel-line); display: flex; gap: 12px; }
.sdet__list li::before { content: ""; width: 8px; height: 8px; margin-top: .55em; flex: none; border: 2px solid var(--argon); transform: rotate(45deg); }
.jump { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 4px; }
.jump::-webkit-scrollbar { display: none; }
.jump a {
  flex: none; padding: 10px 14px; font-size: .9rem; font-weight: 600;
  background: rgba(26, 31, 36, .7);
  -webkit-backdrop-filter: blur(10px) saturate(130%); backdrop-filter: blur(10px) saturate(130%);
  box-shadow: inset 0 0 0 1px rgba(230, 234, 238, .2);
  color: var(--on-dark); border-radius: 2px;
  transition: background .3s, color .3s, box-shadow .3s;
}
.jump a:hover { background: var(--argon); color: #fff; box-shadow: none; }
/* Kad red čipova ima još sadržaja desno, ivica se stapa umesto da se preseče */
.jump.has-fade {
  -webkit-mask-image: linear-gradient(90deg, #000 0, #000 calc(100% - 64px), transparent 100%);
          mask-image: linear-gradient(90deg, #000 0, #000 calc(100% - 64px), transparent 100%);
}

/* product cells (CNC) */
.prod { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--steel-line); border: 1px solid var(--steel-line); }
.prod li { background: var(--plate); padding: 20px 16px; min-height: 120px; display: flex; flex-direction: column; justify-content: space-between; gap: 18px; transition: background .4s var(--ease), color .4s; }
.prod li:hover { background: var(--graphite); color: var(--on-dark); }
.prod svg { width: 34px; height: 34px; }
.prod b { font-stretch: 110%; font-weight: 700; font-size: 1.05rem; line-height: 1.2; }
@media (min-width: 760px) { .prod { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1000px) { .prod { grid-template-columns: repeat(5, 1fr); } }

/* gallery */
.gal { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.gal a { position: relative; display: block; aspect-ratio: 3/4; overflow: hidden; background: var(--graphite-2) url("../assets/plate.svg") center / 60px; }
.gal a:nth-child(5n+1) { grid-row: span 2; aspect-ratio: auto; }
.gal img { width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease); }
.gal a:hover img { transform: scale(1.05); }
@media (min-width: 760px) { .gal { grid-template-columns: repeat(4, 1fr); gap: 12px; } }

/* knowledge articles */
.know { display: grid; gap: 1px; background: var(--dark-line); border: 1px solid var(--dark-line); }
.know article { background: var(--graphite); padding: clamp(22px, 4vw, 40px); }
.know h3 { margin-bottom: 14px; }
.know p { color: var(--on-dark-muted); }
@media (min-width: 1000px) { .know { grid-template-columns: 1fr 1fr; } }

/* table */
.tbl-wrap { overflow-x: auto; border: 1px solid var(--steel-line); }
.tbl { width: 100%; min-width: 640px; border-collapse: collapse; font-size: .93rem; }
.tbl th, .tbl td { text-align: left; padding: 14px 16px; border-bottom: 1px solid var(--steel-line); vertical-align: top; }
.tbl th { font-weight: 600; color: var(--muted); font-size: .82rem; background: var(--plate); }
.tbl td:first-child { font-weight: 700; font-stretch: 110%; white-space: nowrap; }
.tbl tr { transition: background .25s; }
.tbl tbody tr:hover { background: var(--plate); }

/* FAQ */
.faq { border-top: 1px solid var(--steel-line); }
.faq details { border-bottom: 1px solid var(--steel-line); }
.faq summary {
  list-style: none; cursor: pointer;
  display: flex; justify-content: space-between; align-items: center; gap: 18px;
  padding: 20px 0; font-weight: 650; font-size: clamp(1.02rem, 1.8vw, 1.2rem);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary i { position: relative; flex: none; width: 18px; height: 18px; }
.faq summary i::before, .faq summary i::after { content: ""; position: absolute; left: 0; right: 0; top: 8px; height: 2px; background: currentColor; transition: transform .4s var(--ease); }
.faq summary i::after { transform: rotate(90deg); }
.faq details[open] summary i::after { transform: rotate(0); }
.faq .ans { padding: 0 0 22px; color: var(--muted); max-width: 70ch; }

/* ---------- Contact ---------- */
.contact { display: grid; gap: 36px; }
.form { display: grid; gap: 14px; }
.form__row { display: grid; gap: 14px; }
.form label { display: grid; gap: 6px; font-size: .88rem; color: var(--muted); }
.form textarea.inp { min-height: 150px; resize: vertical; }
.form select.inp { appearance: none; background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231A1F24' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center / 18px; padding-right: 40px; }
.form__note { font-size: .85rem; color: var(--muted); }
.form__msg { font-size: .92rem; padding: 12px 14px; background: var(--plate); border-left: 3px solid var(--argon); display: none; }
.form__msg.is-on { display: block; }
.form .err { box-shadow: inset 0 0 0 2px #C0392B; }
.map { position: relative; aspect-ratio: 4/3; border: 1px solid var(--steel-line); overflow: hidden; background: var(--plate); }
.map iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; filter: grayscale(1) contrast(1.05); }
.hours { border-top: 1px solid var(--steel-line); }
.hours li { display: flex; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid var(--steel-line); }
.hours li.is-today { font-weight: 700; }
.hours li.is-today span:last-child { color: var(--argon-deep); }

/* ==========================================================================
   AI asistent (bez API-ja) — dole levo
   ========================================================================== */
.ai-fab {
  position: fixed; left: var(--fab-gap); bottom: var(--fab-gap); z-index: 85;
  height: var(--fab); min-width: var(--fab);
  display: inline-flex; align-items: center; gap: 10px;
  padding: 0 18px 0 6px;
  background: var(--graphite); color: #fff; border-radius: 999px;
  box-shadow: 0 10px 30px -10px rgba(26, 31, 36, .6), inset 0 0 0 1px rgba(255, 255, 255, .08);
  transition: background .3s, transform .5s var(--ease), padding .4s var(--ease);
}
.ai-fab:hover { background: var(--argon-deep); }
.ai-fab__ico {
  position: relative; width: 44px; height: 44px; border-radius: 50%;
  display: grid; place-items: center;
  background: radial-gradient(circle at 50% 50%, #fff 0 12%, #9EA6FF 28%, var(--argon) 52%, var(--argon-deep) 100%);
  box-shadow: 0 0 16px 2px rgba(91, 99, 246, .55);
  animation: arcglow 3.2s ease-in-out infinite;
}
.ai-fab__ico svg { width: 20px; height: 20px; color: #fff; }
@keyframes arcglow { 50% { box-shadow: 0 0 22px 5px rgba(91, 99, 246, .75); } }
.ai-fab__lbl { font-weight: 650; font-size: .95rem; white-space: nowrap; }
.ai-fab__dot { position: absolute; top: 2px; right: 2px; width: 12px; height: 12px; border-radius: 50%; background: var(--gold); border: 2px solid var(--graphite); }
.ai-open .ai-fab { transform: scale(.9); opacity: 0; pointer-events: none; }

.ai {
  position: fixed; left: var(--fab-gap); bottom: var(--fab-gap); z-index: 120;
  width: calc(100vw - var(--fab-gap) * 2); max-width: 400px;
  height: min(620px, calc(100svh - var(--fab-gap) * 2 - 10px));
  display: flex; flex-direction: column;
  background: var(--plate); color: var(--ink);
  border-radius: 6px; overflow: hidden;
  box-shadow: 0 40px 80px -24px rgba(15, 19, 22, .55), 0 0 0 1px var(--steel-line);
  transform-origin: bottom left;
  transform: translateY(16px) scale(.96); opacity: 0; visibility: hidden;
  transition: transform .45s var(--ease), opacity .3s, visibility .3s;
}
.ai-open .ai { transform: none; opacity: 1; visibility: visible; }
.ai__hd { display: flex; align-items: center; gap: 12px; padding: 14px 14px 14px 16px; background: var(--graphite); color: var(--on-dark); }
.ai__av { width: 38px; height: 38px; border-radius: 50%; flex: none; background: radial-gradient(circle, #fff 0 12%, #9EA6FF 28%, var(--argon) 52%, var(--argon-deep)); box-shadow: 0 0 14px rgba(91, 99, 246, .6); }
.ai__who { flex: 1; line-height: 1.25; }
.ai__who b { display: block; font-stretch: 110%; }
.ai__who span { font-size: .8rem; color: var(--on-dark-muted); display: flex; align-items: center; gap: 6px; }
.ai__who span::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #54D38A; }
.ai__x { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; color: var(--on-dark); }
.ai__x:hover { background: rgba(255, 255, 255, .08); }
.ai__x svg { width: 18px; height: 18px; }
.ai__log { flex: 1; overflow-y: auto; padding: 16px 14px; display: flex; flex-direction: column; gap: 10px; scroll-behavior: smooth; overscroll-behavior: contain; }
.msg { max-width: 86%; padding: 10px 13px; border-radius: 14px; font-size: .93rem; line-height: 1.5; animation: msgin .4s var(--ease); }
.msg a { color: var(--argon-deep); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.msg ul { margin: 6px 0 0; padding-left: 0; }
.msg li { position: relative; padding-left: 14px; margin: 3px 0; }
.msg li::before { content: ""; position: absolute; left: 0; top: .7em; width: 6px; height: 2px; background: var(--argon); }
.msg--bot { align-self: flex-start; background: #fff; border-bottom-left-radius: 4px; box-shadow: 0 0 0 1px var(--steel-line); }
.msg--me { align-self: flex-end; background: var(--graphite); color: #fff; border-bottom-right-radius: 4px; }
@keyframes msgin { from { opacity: 0; transform: translateY(8px); } }
.typing { display: inline-flex; gap: 4px; padding: 14px 14px; }
.typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--muted); animation: typ 1s infinite; }
.typing i:nth-child(2) { animation-delay: .15s; }
.typing i:nth-child(3) { animation-delay: .3s; }
@keyframes typ { 30% { transform: translateY(-4px); opacity: 1; } 0%, 60%, 100% { opacity: .4; } }
.ai__quick { display: flex; gap: 6px; overflow-x: auto; padding: 0 14px 10px; scrollbar-width: none; }
.ai__quick::-webkit-scrollbar { display: none; }
.ai__quick button {
  flex: none; padding: 8px 12px; min-height: 36px; border-radius: 999px; font-size: .84rem; font-weight: 600;
  background: #fff; box-shadow: inset 0 0 0 1px var(--steel-line-2);
  transition: background .25s, color .25s, box-shadow .25s;
}
.ai__quick button:hover { background: var(--argon); color: #fff; box-shadow: none; }
.ai__form { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--steel-line); background: #fff; }
.ai__in { flex: 1; min-width: 0; min-height: 46px; padding: 0 14px; border: 0; border-radius: 999px; background: var(--plate); font-size: 16px; }
.ai__in:focus { outline: none; box-shadow: inset 0 0 0 2px var(--argon); }
.ai__send { width: 46px; height: 46px; flex: none; display: grid; place-items: center; border-radius: 50%; background: var(--argon); color: #fff; transition: background .3s; }
.ai__send:hover { background: var(--graphite); }
.ai__send svg { width: 18px; height: 18px; }
.ai__note { font-size: .72rem; color: var(--muted); text-align: center; padding: 0 12px 8px; background: #fff; }

/* ==========================================================================
   Breakpoints
   ========================================================================== */
@media (min-width: 560px) {
  .ai-fab__lbl { display: inline; }
  .grid { grid-template-columns: repeat(2, 1fr); }
  .form__row { grid-template-columns: 1fr 1fr; }
  .cta__cards { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 559px) {
  .ai-fab { padding: 0 6px; }
  .ai-fab__lbl { display: none; }
}

/* Uži telefoni: kompaktnije kontrole slajdera da stanu u jedan red */
@media (max-width: 759px) {
  .hero { --ctrl-h: 36px; --ctrl-gap: 8px; --ctrl-clear: 10px; }
  .hero__ctrl { gap: 10px; }
  .hctr { font-size: .74rem; letter-spacing: .05em; }
  .hbar { width: 22px; }
  .hbars { gap: 5px; }
  .hbtn { width: 36px; height: 36px; }
  .hbtns { gap: 5px; }
  /* Na telefonu tekst ide preko cele širine, pa zatamnjenje mora biti ravnomernije */
  .hero__shade {
    background:
      linear-gradient(90deg, rgba(26, 31, 36, .92) 0%, rgba(26, 31, 36, .84) 60%, rgba(26, 31, 36, .68) 100%),
      linear-gradient(180deg, rgba(26, 31, 36, .7) 0%, rgba(26, 31, 36, .42) 26%, rgba(26, 31, 36, .84) 74%, var(--graphite) 100%),
      linear-gradient(rgba(46, 93, 168, .16), rgba(46, 93, 168, .16));
  }
}

/* Isto važi i za podstranice: ispod 1000 px nema praznog desnog dela,
   pa fotografija mora da ide dublje u pozadinu radi čitljivosti (AA). */
@media (max-width: 999px) {
  .phero__shade {
    background:
      linear-gradient(90deg, rgba(26, 31, 36, .9) 0%, rgba(26, 31, 36, .8) 55%, rgba(26, 31, 36, .68) 100%),
      linear-gradient(180deg, rgba(26, 31, 36, .5) 0%, rgba(26, 31, 36, .34) 22%, rgba(26, 31, 36, .82) 72%, var(--graphite) 100%),
      linear-gradient(rgba(46, 93, 168, .16), rgba(46, 93, 168, .16));
  }
}

@media (min-width: 760px) {
  :root { --hdr: 76px; }
  .mats { grid-template-columns: repeat(3, 1fr); }
  .titleblock { grid-template-columns: repeat(4, 1fr); }
  .titleblock > div { border-right: 1px solid var(--dark-line); padding: 16px 16px; }
  .titleblock > div:first-child { padding-left: 0; }
  .titleblock > div:last-child { border-right: 0; }
  .hero__row { grid-template-columns: 1.1fr .9fr; align-items: end; }
  .hero__actions { justify-content: flex-end; }
  .hero__hint { display: flex; }
  .sec__head { grid-template-columns: 1.1fr .9fr; align-items: end; }
  .svc__row { grid-template-columns: 1fr minmax(0, 34ch) auto; }
  .svc__meta { grid-column: auto; }
  .facts { grid-template-columns: repeat(4, 1fr); }
  .fact { border-right: 1px solid var(--steel-line); padding-left: 16px; }
  .fact:first-child { padding-left: 0; }
  .fact:last-child { border-right: 0; }
  .tb { grid-template-columns: repeat(4, 1fr); }
  .tb > div:nth-child(2n) { border-right: 1px solid var(--dark-line); }
  .tb > div:nth-child(4n) { border-right: 0; }
  .ftr__cols { grid-template-columns: repeat(3, 1fr); }
  .calc__row { gap: 14px; }
  .step { grid-template-columns: 40px 1fr; }
}

@media (min-width: 1000px) {
  .nav { display: block; }
  .burger { display: none; }
  .hdr__cta { display: inline-flex; min-height: 44px; padding: 0 18px; }
  .hdr__phone { display: inline-block; font-weight: 600; font-size: .95rem; color: var(--on-dark-muted); transition: color .3s; }
  .hdr__phone:hover { color: var(--on-dark); }
  .hdr__right { display: flex; align-items: center; gap: 18px; }
  .mats { grid-template-columns: repeat(6, 1fr); }
  .mat { min-height: 330px; padding: 20px 18px 22px; }
  .proc { grid-template-columns: 1.05fr .95fr; gap: 48px; align-items: start; }
  .proc__tabs { grid-column: 1 / -1; margin: 0; padding: 0; flex-wrap: wrap; }
  .cnc { grid-template-columns: 1.1fr .9fr; gap: 64px; }
  .gen { grid-template-columns: 1.35fr .65fr; gap: 40px; }
  .about { grid-template-columns: .8fr 1.2fr; gap: 72px; align-items: center; }
  .cta__row { grid-template-columns: 1fr 1fr; align-items: end; }
  .ftr__top { grid-template-columns: 1fr 1.4fr; }
  .grid { grid-template-columns: repeat(3, 1fr); }
  .sdet { grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
  .sdet:nth-of-type(even) .sdet__img { order: 2; }
  .contact { grid-template-columns: 1.1fr .9fr; gap: 64px; }
  .steps--split { display: grid; grid-template-columns: .9fr 1.1fr; gap: 64px; }
}

@media (min-width: 1000px) and (pointer: fine) {
  body.has-cursor, body.has-cursor a, body.has-cursor button, body.has-cursor .rail { cursor: none; }
  body.has-cursor input, body.has-cursor textarea, body.has-cursor select { cursor: auto; }
  .cursor {
    display: block; position: fixed; left: 0; top: 0; z-index: 300; pointer-events: none;
    mix-blend-mode: difference;
  }
  .cursor__dot { position: fixed; left: -3px; top: -3px; width: 6px; height: 6px; background: #fff; border-radius: 50%; }
  .cursor__ring {
    position: fixed; left: -18px; top: -18px; width: 36px; height: 36px;
    transition: width .35s var(--ease), height .35s var(--ease), left .35s var(--ease), top .35s var(--ease);
  }
  .cursor__ring::before, .cursor__ring::after { content: ""; position: absolute; background: #fff; }
  .cursor__ring::before { left: 50%; top: 0; bottom: 0; width: 1px; transform: translateX(-50%); -webkit-mask: linear-gradient(#000 0 30%, transparent 30% 70%, #000 70%); mask: linear-gradient(#000 0 30%, transparent 30% 70%, #000 70%); }
  .cursor__ring::after { top: 50%; left: 0; right: 0; height: 1px; transform: translateY(-50%); -webkit-mask: linear-gradient(90deg, #000 0 30%, transparent 30% 70%, #000 70%); mask: linear-gradient(90deg, #000 0 30%, transparent 30% 70%, #000 70%); }
  .cursor.is-link .cursor__ring { width: 64px; height: 64px; left: -32px; top: -32px; }
  .cursor.is-link .cursor__ring::before, .cursor.is-link .cursor__ring::after { opacity: .5; }
  .cursor.is-link .cursor__ring { border: 1px solid #fff; border-radius: 50%; }
  .cursor.is-hidden { opacity: 0; }
}

/* Parallaks na fotografiji podstranice — samo na širokim ekranima */
@media (min-width: 1000px) {
  .phero__media img { transform: translateY(var(--py, 0%)); will-change: transform; }
}

@media (min-width: 1400px) {
  .hero__title { font-size: min(11.5rem, 17.5svh); }
}

/* Niski ekrani: naslov i razmaci se skupljaju da sadržaj stane u jedan viewport.
   Ova dva bloka idu posle širinskih tačaka prekida jer moraju da ih nadjačaju. */
@media (max-height: 720px) {
  .hero { --hero-top: 8px; }
  .hero__title { font-size: clamp(2.2rem, min(14.5vw, 15svh), 11rem); }
  .hero__seam { height: 22px; margin: 4px 0 12px; }
  .hero__kicker { margin-bottom: 12px; }
  .hero__row { gap: 14px; }
  .hero__actions { gap: 8px; }
}

/* Telefon u pejzažu: duži pasus se sklanja, naslov i oba dugmeta ostaju.
   Red se spušta na jednu kolonu da dugmad stanu u jedan red. */
@media (orientation: landscape) and (max-height: 520px) {
  .hero { --hero-top: 6px; --ctrl-h: 34px; --ctrl-gap: 8px; --ctrl-clear: 8px; }
  .hero__title { font-size: min(9vw, 10.5svh); }
  .hero__txt { display: none; }
  .hero__row { grid-template-columns: 1fr; gap: 0; }
  .hero__actions { justify-content: flex-start; }
  .hero__seam { height: 14px; margin: 2px 0 8px; }
  .hero__kicker { margin-bottom: 8px; font-size: .8rem; }
  .hero__hint { display: none; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  [data-reveal], [data-cut] { opacity: 1; transform: none; clip-path: none; }
  .phero__title .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .08em; margin-bottom: -.08em; }
.phero__title .ch { transform: none; opacity: 1; }
  .marquee__track { animation: none; }
  /* Slajder: bez Ken Burns zuma i bez parallaksa, prelaz je trenutan */
  .hslide img { animation: none !important; transform: none !important; }
  .phero__media img { transform: none !important; }
}

@media print {
  .hdr, .ai, .ai-fab, .totop, .progress, .cursor, .hero__canvas,
  .hero__media, .hero__shade, .hero__ctrl, .phero__media, .phero__shade { display: none !important; }
  .hero { height: auto; }
  .dark { background: #fff; color: #000; }
}
