/* Mobile-first. Boje i fontovi dolaze iz brand.json kao CSS varijable (vidi <style> u index.html).
   MASCH-PRO: svijetla bež podloga, tamna tipografija, tanke linije, uglovi skoro ravni. */
*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 4.5rem; }
body {
  margin: 0;
  font-family: var(--font-tekst);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--tekst);
  background: var(--pozadina);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--primarna); text-underline-offset: 3px; }
h1, h2, h3 { font-family: var(--font-naslovi); line-height: 1.15; margin: 0 0 .6em; letter-spacing: -.01em; }
h1 { font-size: clamp(2rem, 6.4vw, 3.4rem); font-weight: 700; letter-spacing: -.025em; }
h2 { font-size: clamp(1.6rem, 4.5vw, 2.4rem); font-weight: 700; letter-spacing: -.02em; }
h3 { font-size: 1.15rem; font-weight: 700; }
p { margin: 0 0 1em; }
ul, ol { list-style: none; padding: 0; margin: 0; }

:focus-visible { outline: 3px solid var(--primarna); outline-offset: 3px; }
.section--dark :focus-visible, .foot :focus-visible { outline-color: var(--akcent); }

.sprite { position: absolute; }
.skip { position: absolute; left: -9999px; top: 0; background: var(--pozadina); padding: .5rem 1rem; z-index: 100; }
.skip:focus { left: 1rem; }

.wrap { width: min(100% - 2.5rem, 72rem); margin-inline: auto; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px;
  padding: .8rem 1.4rem;
  border: 2px solid var(--primarna);
  border-radius: 3px;
  background: var(--primarna);
  color: var(--primarna-tekst);
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  transition: background-color .15s ease, color .15s ease;
}
.btn:hover { background: var(--tekst); border-color: var(--tekst); }
.btn--small { min-height: 44px; padding: .5rem 1rem; font-size: .95rem; }
.btn--ghost { background: transparent; color: var(--tekst); border-color: var(--tekst); }
.btn--ghost:hover { background: var(--tekst); color: var(--pozadina); }
.btn--light { background: var(--pozadina); border-color: var(--pozadina); color: var(--tekst); }
.btn--light:hover { background: var(--akcent); border-color: var(--akcent); }

/* zaglavlje */
.top { position: sticky; top: 0; z-index: 10; background: var(--pozadina); border-bottom: 1px solid var(--akcent); }
.top__in { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; min-height: 4rem; }
.brand { font-family: var(--font-naslovi); font-weight: 800; font-size: 1.2rem; letter-spacing: .08em; color: var(--tekst); text-decoration: none; }
.nav { display: none; }
.top .btn--small { display: none; }

/* hero */
.hero { padding: 2rem 0 3rem; border-bottom: 1px solid var(--akcent); }
.hero__in { display: grid; gap: 2rem; }
.eyebrow { color: var(--prigusen); font-weight: 600; font-size: .85rem; letter-spacing: .12em; text-transform: uppercase; margin-bottom: 1rem; }
.lead { font-size: 1.15rem; color: var(--prigusen); max-width: 36rem; }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.75rem; }
.actions .btn { flex: 1 1 12rem; }
.hero__img { margin: 0; }
.hero__img img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 3px; }

/* sekcije */
.section { padding: 3.5rem 0; }
.section--alt { background: var(--povrsina); }
.section__head { margin-bottom: 2rem; max-width: 40rem; }
.section__head p { color: var(--prigusen); }

/* kategorije */
.cats { display: grid; border-top: 1px solid var(--akcent); }
.cat { padding: 1.75rem 0; border-bottom: 1px solid var(--akcent); }
.cat__top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 1.25rem; }
.icon { width: 44px; height: 44px; fill: none; stroke: var(--tekst); stroke-width: 2.25; stroke-linecap: round; stroke-linejoin: round; }
.icon .accent { stroke: var(--primarna); }
.cat__no { font-size: .9rem; font-weight: 700; color: var(--prigusen); font-variant-numeric: tabular-nums; }
.cat h3 { font-size: 1.3rem; margin-bottom: .3em; }
.cat__opis { color: var(--prigusen); }
.cat__list li { position: relative; padding: .45rem 0 .45rem 1.25rem; border-top: 1px dashed var(--akcent); font-size: 1rem; }
.cat__list li::before { content: ""; position: absolute; left: 0; top: 1.05rem; width: .55rem; height: 2px; background: var(--primarna); }
.cat--cta { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; }
.cat--cta .btn { margin-top: .5rem; }

/* za koga / zašto */
.cols { display: grid; gap: 1.5rem; }
.cols li { border-top: 2px solid var(--tekst); padding-top: 1rem; }
.cols p { color: var(--prigusen); margin: 0; }
.cols--num { counter-reset: n; }
.cols--num li { counter-increment: n; }
.cols--num h3::before { content: counter(n, decimal-leading-zero); display: block; font-size: .9rem; color: var(--primarna); margin-bottom: .5rem; }

/* upit */
.section--dark { background: var(--tekst); color: var(--pozadina); }
.section--dark a { color: var(--pozadina); }
.section--dark .lead { color: var(--akcent); }
.contact { display: grid; gap: 2.5rem; }
.contact__list li { padding: .7rem 0; border-bottom: 1px solid #4a453e; }
.contact__list a { font-weight: 600; font-size: 1.1rem; overflow-wrap: anywhere; }
.label { display: block; font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--akcent); }

.form { display: grid; gap: 1.1rem; }
.field label { display: block; font-weight: 600; margin-bottom: .35rem; }
.opt { font-weight: 400; color: var(--akcent); }
.field input, .field textarea {
  width: 100%; min-height: 48px; padding: .7rem .85rem;
  font: inherit; color: var(--pozadina);
  background: #2a2724; border: 1px solid #8c8377; border-radius: 3px;
}
.field textarea { resize: vertical; min-height: 8rem; }
.field input:focus-visible, .field textarea:focus-visible { outline-offset: 0; border-color: var(--akcent); }
.field ::placeholder { color: #a39a8c; }
.form__err { margin: 0; padding: .6rem .8rem; background: #f4d9cf; color: #6b1d0c; border-radius: 3px; font-weight: 600; }
.form__note { margin: 0; font-size: .9rem; color: var(--akcent); }
.form .btn { justify-self: start; }

/* podnožje */
.foot { padding: 2.5rem 0 6rem; /* dno: mjesto za sticky CTA na mobitelu */ background: var(--tekst); color: var(--pozadina); font-size: .95rem; border-top: 1px solid #4a453e; }
.foot__in { display: grid; gap: .4rem; }
.foot p { margin: 0; }
.foot a { color: inherit; }
.credit { color: var(--akcent); font-size: .85rem; margin-top: .75rem !important; }

.sticky-cta {
  position: fixed; left: .75rem; right: .75rem; bottom: .75rem; z-index: 20;
  min-height: 52px; display: flex; align-items: center; justify-content: center;
  border-radius: 3px; background: var(--primarna); color: var(--primarna-tekst);
  font-weight: 700; text-decoration: none; box-shadow: 0 6px 20px rgb(0 0 0 / .18);
  transition: transform .2s ease;
}
.sticky-cta.is-hidden { transform: translateY(150%); }

@media (min-width: 768px) {
  .foot { padding-bottom: 2.5rem; }
  .sticky-cta { display: none; }
  .top .btn--small { display: inline-flex; }
  .nav { display: flex; gap: 1.75rem; margin-left: auto; }
  .nav a { color: var(--tekst); text-decoration: none; font-weight: 600; font-size: .95rem; padding: .5rem 0; }
  .nav a:hover { text-decoration: underline; }
  .actions .btn { flex: 0 0 auto; }
  .section { padding: 5rem 0; }
  .cats { grid-template-columns: repeat(2, 1fr); border-top: 0; border-left: 1px solid var(--akcent); }
  .cat { padding: 2rem 1.75rem; border-right: 1px solid var(--akcent); border-top: 1px solid var(--akcent); border-bottom: 0; }
  .cats { border-bottom: 1px solid var(--akcent); }
  .cols { grid-template-columns: repeat(3, 1fr); gap: 2rem; }
}

@media (min-width: 960px) {
  .hero { padding: 4.5rem 0; }
  .hero__in { grid-template-columns: 1.1fr 1fr; align-items: center; gap: 4rem; }
  .cats { grid-template-columns: repeat(3, 1fr); }
  .contact { grid-template-columns: 1fr 1.15fr; gap: 4rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .sticky-cta, .btn { transition: none; }
}
