/* ENGAM javna stranica. Boje iz loga: plava ENG (#0560ba) i skoro-crna AM. */
:root {
  --brand: #0560ba;
  --brand-dark: #04468a;
  --brand-soft: #e8f1fb;
  --ink: #0f1720;
  --text: #2d3744;
  --muted: #5f6b7a;
  --line: #e2e8f0;
  --tint: #f4f7fb;
  --white: #fff;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(15, 23, 32, .05), 0 8px 24px rgba(15, 23, 32, .06);
  --container: 1180px;
  --header-h: 72px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--white); color: var(--text);
  font: 17px/1.65 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand); }
h1, h2, h3 { color: var(--ink); line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(32px, 5vw, 52px); font-weight: 800; letter-spacing: -.025em; }
h2 { font-size: clamp(26px, 3.2vw, 36px); font-weight: 750; letter-spacing: -.02em; }
h3 { font-size: 19px; font-weight: 700; }
p { margin: 0 0 1em; }
strong { color: var(--ink); }
.sr, .skip:not(:focus) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip:focus { position: fixed; top: 8px; left: 8px; z-index: 100; background: var(--white); padding: 8px 14px; border-radius: 8px; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.container.narrow { max-width: 860px; }
.center { text-align: center; }

/* --------------------------------------------------------------- dugmad */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 24px; border-radius: 10px; border: 2px solid transparent;
  font: inherit; font-size: 16px; font-weight: 650; line-height: 1.2; text-decoration: none;
  cursor: pointer; transition: background .15s, color .15s, border-color .15s, transform .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--brand); color: var(--white); }
.btn-primary:hover { background: var(--brand-dark); }
.btn-ghost { background: transparent; color: var(--brand); border-color: currentColor; }
.btn-ghost:hover { background: var(--brand-soft); }
.btn-light { background: var(--white); color: var(--brand); }
.btn-light:hover { background: var(--brand-soft); }
.btn-sm { padding: 8px 14px; font-size: 14px; border-width: 1.5px; }
.btn:disabled { opacity: .6; cursor: default; transform: none; }

/* ---------------------------------------------------------- zaglavlje */
.site-header {
  position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .92);
  backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); gap: 24px; }
.logo img { width: 150px; height: auto; }

.site-nav > ul { display: flex; align-items: center; gap: 2px; list-style: none; margin: 0; padding: 0; }
.site-nav a {
  display: block; padding: 8px 12px; border-radius: 8px; font-size: 15px; font-weight: 600;
  color: var(--text); text-decoration: none; white-space: nowrap;
}
.site-nav a:hover { color: var(--brand); background: var(--tint); }
.site-nav a.active { color: var(--brand); }
.has-sub { position: relative; }
.has-sub > a::after { content: ""; display: inline-block; width: 6px; height: 6px; margin-left: 7px; border: solid currentColor; border-width: 0 1.8px 1.8px 0; transform: translateY(-3px) rotate(45deg); }
.sub {
  position: absolute; top: 100%; left: 0; min-width: 250px; list-style: none; margin: 0; padding: 8px;
  background: var(--white); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow);
  opacity: 0; visibility: hidden; transform: translateY(6px); transition: .15s;
}
.has-sub:hover .sub, .has-sub:focus-within .sub { opacity: 1; visibility: visible; transform: none; }
.sub a { font-weight: 550; }
.nav-portal a { margin-left: 8px; background: var(--brand); color: var(--white) !important; padding: 9px 16px; }
.nav-portal a:hover { background: var(--brand-dark); }
.nav-lang a { margin-left: 6px; font-size: 13px; letter-spacing: .04em; color: var(--muted); border: 1px solid var(--line); padding: 6px 10px; }

.nav-toggle { display: none; background: none; border: 0; width: 44px; height: 44px; padding: 10px; cursor: pointer; }
.nav-toggle span:not(.sr) { display: block; height: 2px; background: var(--ink); margin: 5px 0; border-radius: 2px; transition: .2s; }
.nav-open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* -------------------------------------------------------------- hero */
.hero {
  padding: 72px 0 88px; overflow: hidden;
  background: radial-gradient(900px 480px at 85% 10%, var(--brand-soft), transparent 70%), linear-gradient(180deg, #fff, var(--tint));
}
.hero-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; }
.hero h1 span { color: var(--brand); }
.hero .lead { font-size: 19px; max-width: 560px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0 36px; }
.hero-points { display: flex; flex-wrap: wrap; gap: 28px; list-style: none; margin: 0; padding: 22px 0 0; border-top: 1px solid var(--line); }
.hero-points li { font-size: 14px; color: var(--muted); max-width: 150px; line-height: 1.35; }
.hero-points strong { display: block; font-size: 26px; color: var(--brand); line-height: 1.2; }
.hero-media { position: relative; }
.hero-img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 24px; box-shadow: 0 30px 60px rgba(5, 96, 186, .18); }
.hero-badge {
  position: absolute; left: -28px; bottom: -28px; width: 128px; background: var(--white);
  border-radius: 18px; padding: 8px; box-shadow: var(--shadow);
}
.eyebrow { margin: 0 0 10px; font-size: 13px; font-weight: 750; text-transform: uppercase; letter-spacing: .12em; color: var(--brand); }
.lead { font-size: 18px; color: var(--muted); }

/* ---------------------------------------------------- zaglavlje stranice */
.page-hero { position: relative; isolation: isolate; padding: 96px 0 80px; color: var(--white); overflow: hidden; background: var(--ink); }
.page-hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: right center; z-index: -2; }
.page-hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(90deg, rgba(6, 16, 34, .96) 0%, rgba(6, 16, 34, .86) 30%, rgba(6, 16, 34, .3) 60%, rgba(6, 16, 34, 0) 78%),
    linear-gradient(0deg, rgba(6, 16, 34, .45) 0%, rgba(6, 16, 34, 0) 45%);
}
.page-hero h1 { color: var(--white); max-width: 820px; }
.page-hero h1::after { content: ""; display: block; width: 72px; height: 4px; margin-top: 18px; border-radius: 2px; background: #ff8a1f; box-shadow: 0 0 18px rgba(255, 138, 31, .6); }
.page-hero p { font-size: 20px; max-width: 720px; color: rgba(255, 255, 255, .86); margin: 0; }
.crumbs { font-size: 14px; margin-bottom: 18px; color: rgba(255, 255, 255, .7); }
.crumbs a { color: inherit; text-decoration: none; }
.crumbs a:hover { color: var(--white); text-decoration: underline; }
.crumbs .sep { margin: 0 8px; opacity: .5; }

/* ----------------------------------------------------------- sekcije */
.section { padding: 88px 0; }
.section.tint { background: var(--tint); }
.sec-head { margin-bottom: 28px; }
.sec-head.center { text-align: center; max-width: 760px; margin: 0 auto 44px; }
.sec-head .lead { margin: 0; }
.note { color: var(--muted); font-size: 15px; margin-top: 28px; }
.note.center { max-width: 760px; margin-left: auto; margin-right: auto; }
.lead-p { font-size: 18px; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.split.flip .split-media { order: -1; }
.split-text > :last-child { margin-bottom: 0; }
.split-text h3 { margin-top: 24px; }
.rounded { border-radius: var(--radius); box-shadow: var(--shadow); width: 100%; }
.media-card { display: block; background: var(--white); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); transition: transform .2s; }
.media-card:hover { transform: translateY(-3px); }
.media-card img { width: 100%; max-height: 360px; object-fit: contain; }

.checks { list-style: none; margin: 0 0 1.2em; padding: 0; }
.checks li { position: relative; padding-left: 32px; margin-bottom: 12px; }
.checks li::before {
  content: ""; position: absolute; left: 0; top: .3em; width: 20px; height: 20px; border-radius: 50%;
  background: var(--brand-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 10.5l3 3 6-7' fill='none' stroke='%230560ba' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/100% no-repeat;
}
.checks.small li { font-size: 15.5px; margin-bottom: 10px; }

.features { display: grid; gap: 20px; }
.features.cols-2 { grid-template-columns: repeat(2, 1fr); }
.features.cols-4 { grid-template-columns: repeat(4, 1fr); }
.feature { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.feature p { margin: 0; color: var(--muted); font-size: 15.5px; }
.feature-tag { display: inline-block; font-size: 22px; font-weight: 800; color: var(--brand); margin-bottom: 8px; }

.columns-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.col-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; background: var(--white); }
.possibilities { margin-top: 40px; text-align: center; }
.pills { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; list-style: none; padding: 0; margin: 14px 0 0; }
.pills li { background: var(--brand-soft); color: var(--brand-dark); font-weight: 600; font-size: 15px; padding: 8px 16px; border-radius: 999px; }

/* kartice kategorija na pocetnoj */
.cat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.cat-card {
  display: flex; flex-direction: column; background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px 18px 22px; text-decoration: none; color: var(--text); transition: .2s;
}
.cat-card:hover { border-color: var(--brand); transform: translateY(-3px); box-shadow: var(--shadow); }
.cat-img { height: 170px; margin-bottom: 14px; background: #fff; border-radius: 10px; overflow: hidden; }
.cat-img img { width: 100%; height: 100%; object-fit: contain; }
.cat-card h3 { margin-bottom: 6px; }
.cat-card p { font-size: 15px; color: var(--muted); flex: 1; }
.more { font-weight: 700; color: var(--brand); font-size: 15px; }

.why { display: grid; grid-template-columns: 1.1fr 1fr; gap: 56px; align-items: center; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 0; }
.stats > div { background: var(--ink); color: var(--white); border-radius: var(--radius); padding: 28px 18px; text-align: center; }
.stats dd { margin: 0; font-size: 42px; font-weight: 800; line-height: 1.1; color: var(--white); }
.stats dt { order: 2; font-size: 14px; color: rgba(255, 255, 255, .7); margin-top: 6px; }
.stats > div { display: flex; flex-direction: column-reverse; }
.stats.wide { max-width: 860px; margin: 0 auto; }

/* uvod kategorija */
.points { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin: 32px 0; }
.points.four { grid-template-columns: repeat(4, 1fr); margin: 0; }
.point { border-left: 3px solid var(--brand); background: var(--tint); padding: 20px 22px; border-radius: 0 12px 12px 0; }
.point h3 { font-size: 17px; margin-bottom: 6px; }
.point p { margin: 0; font-size: 15.5px; color: var(--muted); }

.included { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.inc { display: flex; flex-direction: column; gap: 4px; padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); }
.inc-n { font-size: 13px; font-weight: 800; color: var(--brand); letter-spacing: .08em; }
.inc span:last-child { color: var(--muted); font-size: 15px; }

.spec-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.spec { background: var(--white); border-radius: var(--radius); padding: 24px; border: 1px solid var(--line); }
.spec h3 { font-size: 17px; }
.spec ul, .deliver ul { margin: 0; padding-left: 18px; color: var(--muted); font-size: 15.5px; }
.sub-title { text-align: center; margin: 56px 0 20px; font-size: 22px; }
.deliver { max-width: 860px; margin: 0 auto; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.deliver-row { display: grid; grid-template-columns: 260px 1fr; gap: 20px; padding: 18px 24px; border-top: 1px solid var(--line); }
.deliver-row:first-child { border-top: 0; }

/* kartice proizvoda */
.product-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; margin-bottom: 48px; }
.product-grid:last-child { margin-bottom: 0; }
.product-grid.three { grid-template-columns: repeat(3, 1fr); }
.product-grid.one { grid-template-columns: minmax(0, 560px); justify-content: center; }
.product { display: flex; flex-direction: column; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: .2s; }
.product:hover { box-shadow: var(--shadow); }
/* Fiksna visina: renderi su razlicitih proporcija, a kartice u redu moraju biti poravnate. */
.product-img { height: 250px; background: #fff; padding: 16px; border-bottom: 1px solid var(--line); }
.product-img img { width: 100%; height: 100%; object-fit: contain; }
.product-body { display: flex; flex-direction: column; flex: 1; padding: 22px 24px 24px; }
.product-body h3 { margin-bottom: 4px; }
.product-code { font-family: ui-monospace, Consolas, monospace; font-size: 13.5px; color: var(--muted); margin: 0 0 10px; }
.product-body ul { margin: 6px 0 18px; padding-left: 18px; font-size: 15.5px; color: var(--muted); flex: 1; }
.product-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 16px; border-top: 1px solid var(--line); }

/* koncept */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; list-style: none; padding: 0; margin: 0 0 48px; }
.step { position: relative; padding: 30px 26px 26px; border: 1px solid var(--line); border-radius: var(--radius); }
.step-n { display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: var(--brand); color: var(--white); font-weight: 800; font-size: 19px; margin-bottom: 16px; }
.step p { margin: 0; color: var(--muted); }
.big-quote { font-size: clamp(19px, 2.2vw, 24px); line-height: 1.5; text-align: center; max-width: 860px; margin: 0 auto; }
.case { display: grid; grid-template-columns: 1fr 1.3fr; gap: 28px; align-items: start; }
.case figure { margin: 0; }
.case figcaption { font-size: 14.5px; color: var(--muted); margin-top: 12px; }
.center-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; margin-top: 40px; }

/* o nama */
.partners { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; max-width: 900px; margin: 0 auto; }
.partner {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; min-height: 150px;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; text-decoration: none; transition: .2s;
}
.partner:hover { border-color: var(--brand); box-shadow: var(--shadow); }
.partner img { max-height: 48px; width: auto; }
.partner-name { font-size: 30px; font-weight: 800; letter-spacing: .02em; color: var(--ink); }
.partner-visit { font-size: 14px; font-weight: 650; color: var(--brand); }

/* ------------------------------------------------------------- poziv */
.cta { background: linear-gradient(120deg, var(--brand-dark), var(--brand)); color: var(--white); padding: 64px 0; }
.cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.cta h2 { color: var(--white); margin-bottom: 8px; }
.cta p { margin: 0; color: rgba(255, 255, 255, .85); max-width: 620px; }
.cta-actions { display: flex; align-items: center; gap: 20px; flex-shrink: 0; }
.cta-phone { color: var(--white); font-weight: 700; text-decoration: none; white-space: nowrap; }
.cta-phone:hover { text-decoration: underline; }

/* ----------------------------------------------------------- kontakt */
.contact-page { padding-top: 48px; background: linear-gradient(180deg, var(--tint), #fff 60%); }
.contact-page .crumbs { color: var(--muted); }
.contact-page .crumbs a:hover { color: var(--brand); }
.contact-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; align-items: start; }
.contact-info h1 { font-size: clamp(30px, 4vw, 42px); }
.contact-list { list-style: none; padding: 0; margin: 28px 0 0; }
.contact-list li { display: grid; padding: 18px 0; border-top: 1px solid var(--line); }
.ci-label { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin-bottom: 4px; }
.contact-list a { font-size: 18px; font-weight: 650; color: var(--ink); text-decoration: none; }
.contact-list a:hover { color: var(--brand); }
.contact-list small { color: var(--muted); font-size: 14px; }
.contact-form { background: var(--white); border: 1px solid var(--line); border-radius: 18px; padding: 32px; box-shadow: var(--shadow); }
.contact-form h2 { font-size: 24px; margin-bottom: 20px; }
.contact-form label { display: block; font-size: 14px; font-weight: 650; color: var(--ink); margin-bottom: 16px; }
.contact-form input, .contact-form textarea {
  display: block; width: 100%; margin-top: 6px; padding: 12px 14px; font: inherit; font-size: 16px; color: var(--ink);
  background: var(--tint); border: 1.5px solid var(--line); border-radius: 10px; transition: border-color .15s, background .15s;
}
.contact-form textarea { resize: vertical; min-height: 140px; }
.contact-form input:focus, .contact-form textarea:focus { outline: none; border-color: var(--brand); background: #fff; }
.contact-form [aria-invalid="true"] { border-color: #c62828; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.hp { position: absolute !important; left: -9999px; }
.form-msg { margin: 14px 0 0; font-size: 15px; font-weight: 600; min-height: 1.5em; }
.form-msg.ok { color: #1b7a3d; }
.form-msg.err { color: #c62828; }
.contact-form.sent { text-align: center; padding: 56px 32px; }

.notfound { padding: 120px 0; }

/* ------------------------------------------------------------ podnozje */
.site-footer { background: var(--tint); border-top: 1px solid var(--line); padding: 64px 0 0; font-size: 15px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.1fr; gap: 40px; }
.footer-logo img { width: 140px; margin-bottom: 16px; }
.site-footer p { color: var(--muted); max-width: 340px; }
.site-footer h3 { font-size: 13px; text-transform: uppercase; letter-spacing: .12em; color: var(--muted); margin-bottom: 14px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer a { color: var(--text); text-decoration: none; }
.site-footer a:hover { color: var(--brand); }
.site-footer address { font-style: normal; line-height: 1.8; color: var(--text); }
.social { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; }
.footer-bottom { display: flex; justify-content: space-between; gap: 16px; margin-top: 48px; padding: 20px 24px; border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; }

/* --------------------------------------------------------- manji ekrani */
@media (max-width: 1080px) {
  .features.cols-4, .cat-grid, .included, .points.four { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 960px) {
  :root { --header-h: 64px; }
  .nav-toggle { display: block; }
  /* backdrop-filter pravi novi okvir za position:fixed - meni bi se tada vezao
     za zaglavlje umjesto za ekran. Na telefonu zato puna bijela pozadina. */
  .site-header { backdrop-filter: none; background: var(--white); }
  .site-nav {
    position: fixed; inset: var(--header-h) 0 0 0; background: var(--white); padding: 16px 24px 32px;
    overflow-y: auto; transform: translateX(100%); transition: transform .25s; visibility: hidden;
  }
  .nav-open .site-nav { transform: none; visibility: visible; }
  .nav-open { overflow: hidden; }
  .site-nav > ul { flex-direction: column; align-items: stretch; gap: 0; }
  .site-nav a { padding: 14px 8px; font-size: 18px; border-bottom: 1px solid var(--line); border-radius: 0; }
  .has-sub > a::after { display: none; }
  .sub { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; padding: 0 0 0 16px; min-width: 0; }
  .sub a { font-size: 16px; color: var(--muted); }
  .nav-portal a { margin: 20px 0 0; text-align: center; border-radius: 10px; border: 0; }
  .nav-lang a { margin: 12px 0 0; text-align: center; border-radius: 10px; }

  .hero { padding: 48px 0 64px; }
  .hero-grid, .split, .why, .case, .contact-grid { grid-template-columns: 1fr; gap: 40px; }
  .split.flip .split-media { order: 0; }
  .hero-media { max-width: 520px; }
  .hero-badge { left: auto; right: 12px; bottom: -20px; width: 104px; }
  .section { padding: 64px 0; }
  .columns-3, .steps, .spec-grid, .product-grid.three, .partners { grid-template-columns: 1fr; }
  .cta-inner { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .container { padding: 0 16px; }
  .features.cols-2, .features.cols-4, .cat-grid, .included, .points, .points.four,
  .product-grid, .row2, .stats, .footer-grid { grid-template-columns: 1fr; }
  .deliver-row { grid-template-columns: 1fr; gap: 6px; }
  .page-hero { padding: 64px 0 56px; }
  .page-hero-bg { object-position: 70% center; }
  .page-hero::after { background: linear-gradient(180deg, rgba(6, 16, 34, .78) 0%, rgba(6, 16, 34, .9) 100%); }
  .page-hero p { font-size: 17px; }
  .contact-form { padding: 22px 18px; }
  .product-img { height: 210px; }
  .cta-actions { flex-direction: column; align-items: flex-start; gap: 14px; }
  .hero-points { gap: 20px; }
  .footer-bottom { flex-direction: column; padding: 20px 16px; }
}

/* ----------------------------------------------------------- animacije */
/* Sve ispod vrijedi samo uz klasu "motion" (postavlja je motion.js). Bez JS-a
   ili uz iskljucene animacije sadrzaj je odmah vidljiv. */
.site-header { transition: box-shadow .25s, background .25s; }
.site-header.scrolled { box-shadow: 0 6px 24px rgba(15, 23, 32, .08); }

.motion .reveal {
  opacity: 0; transform: translate3d(0, 28px, 0);
  transition: opacity .7s cubic-bezier(.2, .7, .2, 1), transform .7s cubic-bezier(.2, .7, .2, 1);
  transition-delay: var(--d, 0ms);
}
.motion .reveal.from-left { transform: translate3d(-48px, 0, 0) scale(.98); }
.motion .reveal.from-right { transform: translate3d(48px, 0, 0) scale(.98); }
.motion .reveal.in { opacity: 1; transform: none; }
/* Kartice se nakon izranjanja ponovo mogu pomjerati na hover bez kasnjenja. */
.motion .reveal.in.cat-card, .motion .reveal.in.product, .motion .reveal.in.partner, .motion .reveal.in.media-card { transition-delay: 0ms; }

.motion .page-hero-bg { transform: scale(1.08); will-change: transform; }
.motion .page-hero-inner > * { opacity: 0; animation: rise .8s cubic-bezier(.2, .7, .2, 1) forwards; }
.motion .page-hero-inner > :nth-child(2) { animation-delay: .1s; }
.motion .page-hero-inner > :nth-child(3) { animation-delay: .2s; }

/* pocetni ekran */
.motion .hero-text > * { opacity: 0; }
.motion.ready .hero-text > * { animation: rise .8s cubic-bezier(.2, .7, .2, 1) forwards; }
.motion.ready .hero-text > :nth-child(2) { animation-delay: .08s; }
.motion.ready .hero-text > :nth-child(3) { animation-delay: .18s; }
.motion.ready .hero-text > :nth-child(4) { animation-delay: .28s; }
.motion.ready .hero-text > :nth-child(5) { animation-delay: .38s; }
.motion .hero-img { opacity: 0; transform: scale(.94) rotate(-1.5deg); }
.motion.ready .hero-img { animation: hero-in 1.1s .15s cubic-bezier(.2, .7, .2, 1) forwards; }
.motion .hero-badge { opacity: 0; }
.motion.ready .hero-badge { animation: pop .6s .9s cubic-bezier(.3, 1.6, .5, 1) forwards, float 5s 1.6s ease-in-out infinite; }
.hero-media { will-change: transform; }

@keyframes rise { from { opacity: 0; transform: translate3d(0, 24px, 0); } to { opacity: 1; transform: none; } }
@keyframes hero-in { to { opacity: 1; transform: none; } }
@keyframes pop { from { opacity: 0; transform: scale(.6) rotate(-8deg); } to { opacity: 1; transform: none; } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

/* Slike na karticama se blago priblize na hover. */
.product-img img, .cat-img img, .media-card img { transition: transform .5s cubic-bezier(.2, .7, .2, 1); }
.product:hover .product-img img, .cat-card:hover .cat-img img, .media-card:hover img { transform: scale(1.05); }
.btn-primary { box-shadow: 0 6px 16px rgba(5, 96, 186, .22); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}

.shots { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.shots figure { margin: 0; background: var(--white, #fff); border: 1px solid rgba(11,27,43,.1); text-align: center; padding: 12px; }
.shots img { width: 100%; height: auto; display: block; }
.shots figcaption { padding-top: 8px; font-weight: 600; }
@media (max-width: 700px) { .shots { grid-template-columns: 1fr; } }

.demo-video { width: 100%; height: auto; display: block; background: #0b1b2b; border: 1px solid rgba(11,27,43,.15); }

/* Snimci aplikacija u okviru mobitela */
.phones { display: flex; flex-wrap: wrap; justify-content: center; gap: 40px; margin-top: 40px; }
.phone { margin: 0; width: 240px; text-align: center; }
.phone-frame {
  position: relative; background: #0b0f14; border-radius: 36px; padding: 26px 10px;
  box-shadow: 0 0 0 2px #2a313b, 0 24px 48px rgba(15, 23, 32, .18);
}
.phone-frame::before {
  content: ""; position: absolute; top: 11px; left: 50%; transform: translateX(-50%);
  width: 56px; height: 5px; border-radius: 3px; background: #2a313b;
}
.phone-frame img { width: 100%; aspect-ratio: 390 / 844; object-fit: cover; border-radius: 16px; }
.phone figcaption { margin-top: 14px; font-size: 15px; line-height: 1.45; color: var(--muted); }
.split-media .phone { margin: 0 auto; }
@media (max-width: 640px) { .phones { gap: 28px; } .phone { width: 210px; } }

.ec-diagram { display: block; height: auto; }
@media (prefers-reduced-motion: reduce) { .ec-diagram .ec-packet { display: none; } }
.feature-icon { display: inline-flex; align-items: center; justify-content: center; width: 52px; height: 52px; border-radius: 14px; background: var(--brand-soft); color: var(--brand); margin-bottom: 14px; }
.feature-icon svg { width: 28px; height: 28px; }
