/* MGL-Malić Global Logistic — prototip redizajna */
:root {
  --ink: #16172b;
  --ink-2: #222443;
  --blue: #3e38b6;
  --blue-dk: #2f2a94;
  --yellow: #f5b400;
  --yellow-dk: #dca200;
  --paper: #f2f1ec;
  --white: #fff;
  --muted: #5b5d70;
  --muted-lt: #a6a8bb;
  --line: rgba(22, 23, 43, .14);
  --line-lt: rgba(255, 255, 255, .16);
  --f: 'Barlow', system-ui, sans-serif;
  --fc: 'Barlow Semi Condensed', 'Barlow', system-ui, sans-serif;
  --wrap: 1240px;
  --r: 3px;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 400 17px/1.6 var(--f); color: var(--ink); background: var(--white); }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3 { margin: 0; font-family: var(--fc); }
p { margin: 0 0 1em; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 28px; }
.num { font-variant-numeric: tabular-nums; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--blue); color: #fff; padding: 8px 14px; z-index: 99; }
.skip:focus { left: 8px; }
/* podatak koji treba potvrditi sa klijentom */
.ph { text-decoration: underline dotted rgba(62, 56, 182, .75); text-decoration-thickness: 2px; text-underline-offset: 3px; cursor: help; }

/* tipografija */
.h1 { font-size: clamp(40px, 5.6vw, 76px); line-height: .98; font-weight: 700; letter-spacing: -.015em; }
.h2 { font-size: clamp(30px, 3.6vw, 48px); line-height: 1.04; font-weight: 700; letter-spacing: -.01em; }
.h3 { font-size: 24px; line-height: 1.15; font-weight: 700; }
.lead { font-size: clamp(18px, 1.5vw, 21px); line-height: 1.55; color: var(--muted); max-width: 40em; }

/* dugmad */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 50px; padding: 0 24px; border: 2px solid transparent; border-radius: var(--r); font: 600 16px/1 var(--f); text-decoration: none; cursor: pointer; transition: background .2s, color .2s, border-color .2s; }
.btn--blue { background: var(--blue); color: #fff; }
.btn--blue:hover { background: var(--blue-dk); }
.btn--yellow { background: var(--yellow); color: var(--ink); }
.btn--yellow:hover { background: var(--yellow-dk); }
.btn--line { border-color: var(--line); color: var(--ink); background: #fff; }
.btn--line:hover { border-color: var(--ink); }
.link { font-weight: 600; text-decoration: none; border-bottom: 2px solid var(--yellow); padding-bottom: 1px; }
.link:hover { border-color: var(--blue); }

/* header */
.hdr { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .97); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.hdr__in { display: flex; align-items: center; gap: 24px; min-height: 76px; }
.hdr__logo img { width: 168px; height: auto; }
.nav { display: flex; align-items: center; gap: 2px; margin-left: auto; }
.nav a { padding: 10px 12px; font-weight: 500; text-decoration: none; border-radius: var(--r); }
.nav a:hover { background: var(--paper); }
.nav a[aria-current] { box-shadow: inset 0 -3px 0 var(--yellow); border-radius: 0; }
.nav__tel { font-weight: 600 !important; font-variant-numeric: tabular-nums; margin-left: 10px; }
.lang { display: flex; font: 600 13px/1 var(--f); letter-spacing: .04em; border: 1px solid var(--line); border-radius: var(--r); }
.lang a { padding: 8px 9px; text-decoration: none; color: var(--muted); }
.lang a[aria-current] { color: var(--ink); background: var(--paper); }
.hdr__cta { min-height: 44px; padding: 0 18px; font-size: 15px; }
.burger { display: none; width: 44px; height: 44px; border: 0; background: none; padding: 0; cursor: pointer; }
.burger span { display: block; width: 24px; height: 2px; background: var(--ink); margin: 6px auto; transition: transform .25s; }
.burger[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
.burger[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }

/* hero (početna) */
.hero { position: relative; background: var(--ink); color: #fff; }
.hero__img { position: absolute; inset: 0; overflow: hidden; }
.hero__img img { width: 100%; height: 100%; object-fit: cover; object-position: 70% 60%; }
.hero__img::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(22, 23, 43, .92) 0%, rgba(22, 23, 43, .7) 42%, rgba(22, 23, 43, .05) 75%); }
.hero__in { position: relative; padding: clamp(80px, 11vw, 150px) 28px clamp(56px, 7vw, 90px); }
.hero h1 { max-width: 11em; }
.hero p { max-width: 31em; margin: 26px 0 34px; font-size: clamp(18px, 1.5vw, 21px); color: rgba(255, 255, 255, .84); }
.hero__acts { display: flex; flex-wrap: wrap; gap: 14px 22px; align-items: center; }
.hero__tel { font: 600 22px/1 var(--fc); text-decoration: none; font-variant-numeric: tabular-nums; }
.hero__tel small { display: block; margin-bottom: 6px; font: 500 13px/1 var(--f); color: var(--muted-lt); }

/* brzi upit ispod hero-a */
.quick { position: relative; z-index: 2; margin-top: -1px; background: var(--yellow); }
.quick form { display: grid; grid-template-columns: 1fr 1fr 1fr .8fr auto; gap: 0; align-items: stretch; }
.quick label { display: flex; flex-direction: column; justify-content: center; gap: 2px; padding: 14px 18px; border-right: 1px solid rgba(22, 23, 43, .2); font: 600 12px/1 var(--f); letter-spacing: .05em; text-transform: uppercase; color: rgba(22, 23, 43, .7); }
.quick label:first-child { padding-left: 0; }
.quick input, .quick select { width: 100%; padding: 6px 0 0; border: 0; background: none; font: 500 18px/1.3 var(--f); color: var(--ink); text-transform: none; letter-spacing: 0; outline: none; }
.quick input::placeholder { color: rgba(22, 23, 43, .45); }
.quick .btn { margin: 14px 0 14px 18px; background: var(--ink); color: #fff; }
.quick .btn:hover { background: var(--blue); }
.quick__ok { display: none; padding: 26px 0; font-weight: 600; }
.quick.sent form { display: none; }
.quick.sent .quick__ok { display: block; }

/* sekcije */
.sec { padding: clamp(72px, 9vw, 120px) 0; }
.sec--paper { background: var(--paper); }
.sec__head { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 44px; }
.sec__head p { margin: 14px 0 0; max-width: 34em; color: var(--muted); }

/* izbor prikolice (tabovi) */
.tabs { display: flex; gap: 0; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.tabs button { flex: 0 0 auto; padding: 16px 22px 14px; border: 0; background: none; font: 600 18px/1 var(--fc); color: var(--muted); cursor: pointer; box-shadow: inset 0 -3px 0 transparent; transition: color .2s, box-shadow .2s; }
.tabs button:hover { color: var(--ink); }
.tabs button[aria-selected="true"] { color: var(--ink); box-shadow: inset 0 -3px 0 var(--blue); }
.panel { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(32px, 5vw, 72px); padding-top: 44px; align-items: start; }
.panel[hidden] { display: none; }
.panel__fig { color: var(--ink); }
.panel__photo { aspect-ratio: 16 / 10; object-fit: cover; width: 100%; border-radius: var(--r); }
.panel h3 { margin-bottom: 14px; }
.panel p { color: var(--muted); }
.trailer { width: 100%; height: auto; margin-top: 22px; overflow: visible; }
.trailer .t-box { fill: none; stroke: currentColor; stroke-width: 2; }
.trailer .t-cur { stroke: currentColor; stroke-opacity: .22; }
.trailer .t-ch, .trailer .t-wh { fill: none; stroke: currentColor; stroke-width: 2; }
.trailer .t-wh { fill: var(--white); }
.sec--paper .trailer .t-wh { fill: var(--paper); }
.trailer .t-load { fill: none; stroke: var(--blue); stroke-width: 2; }
.trailer .t-gr { stroke: currentColor; stroke-opacity: .3; stroke-dasharray: 2 5; }
.trailer .t-dim { fill: none; stroke: var(--yellow-dk); stroke-width: 1.5; }

/* tehnička tabela */
.spec { width: 100%; margin: 26px 0 30px; border-collapse: collapse; font-size: 16px; }
.spec th, .spec td { padding: 11px 0; border-top: 1px solid var(--line); text-align: left; vertical-align: top; }
.spec th { width: 46%; font-weight: 500; color: var(--muted); }
.spec td { font-weight: 600; font-variant-numeric: tabular-nums; }
.spec tr:last-child th, .spec tr:last-child td { border-bottom: 1px solid var(--line); }

/* baza / o firmi */
.base { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 88px); align-items: center; }
.base img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--r); }
.base .h2 { margin-bottom: 22px; }
.facts { display: grid; grid-template-columns: auto 1fr; gap: 0 28px; margin: 30px 0 0; }
.facts dt, .facts dd { margin: 0; padding: 12px 0; border-top: 1px solid var(--line); }
.facts dt { font-weight: 500; color: var(--muted); }
.facts dd { font-weight: 600; }

/* galerija projekata (horizontalna traka) */
.strip { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(300px, 34%); gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-left: var(--gut); padding: 0 28px 14px var(--gut); scrollbar-width: thin; --gut: max(28px, calc((100vw - var(--wrap)) / 2 + 28px)); }
.strip figure { margin: 0; scroll-snap-align: start; }
.strip button { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; }
.strip img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--r); }
.strip figcaption { padding-top: 12px; font-size: 15px; color: var(--muted); }
.strip figcaption b { display: block; color: var(--ink); font-weight: 600; }
.strip__nav { display: flex; gap: 8px; }
.strip__nav button { width: 46px; height: 46px; border: 1px solid var(--line); border-radius: 50%; background: #fff; font-size: 20px; cursor: pointer; }
.strip__nav button:hover { border-color: var(--ink); }

/* lightbox */
.lb { position: fixed; inset: 0; z-index: 100; display: none; place-items: center; padding: 24px; background: rgba(12, 13, 26, .92); }
.lb.open { display: grid; }
.lb img { max-height: 86vh; width: auto; border-radius: var(--r); }
.lb p { margin: 14px 0 0; color: #fff; text-align: center; }
.lb button { position: absolute; top: 16px; right: 16px; width: 48px; height: 48px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .12); color: #fff; font-size: 26px; cursor: pointer; }

/* vozni park — marke */
.fleet { background: var(--ink); color: #fff; padding: 56px 0; }
.fleet__in { display: grid; grid-template-columns: minmax(220px, 1fr) 2.4fr; gap: 40px; align-items: center; }
.fleet p { margin: 0; color: var(--muted-lt); }
.fleet p b { display: block; margin-bottom: 4px; color: #fff; font: 700 22px/1.2 var(--fc); }
.marks { display: grid; grid-template-columns: repeat(4, 1fr); gap: 36px; align-items: center; }
.marks img { width: 100%; max-height: 46px; object-fit: contain; filter: brightness(0) invert(1); opacity: .8; }

/* CTA iznad futera */
.cta { background: var(--blue); color: #fff; padding: clamp(56px, 7vw, 88px) 0; }
.cta__in { display: flex; justify-content: space-between; align-items: center; gap: 40px; }
.cta p { margin: 14px 0 0; max-width: 36em; color: rgba(255, 255, 255, .8); }
.cta__acts { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; flex-shrink: 0; }
.cta__tel { font: 600 26px/1 var(--fc); text-decoration: none; font-variant-numeric: tabular-nums; }

/* futer */
.ftr { background: var(--ink); color: var(--muted-lt); padding: 64px 0 28px; font-size: 16px; }
.ftr__grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 36px; padding-bottom: 44px; border-bottom: 1px solid var(--line-lt); }
.ftr__brand img { width: 170px; margin-bottom: 18px; }
.ftr h3 { margin-bottom: 12px; font: 600 14px/1 var(--f); letter-spacing: .05em; text-transform: uppercase; color: #fff; }
.ftr a { text-decoration: none; }
.ftr a:hover { color: #fff; }
.ftr__bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding-top: 24px; font-size: 14px; }
.mbar { display: none; }

/* podstranice */
.phead { background: var(--paper); padding: clamp(56px, 7vw, 96px) 0 clamp(40px, 5vw, 64px); border-bottom: 1px solid var(--line); }
.phead .lead { margin-top: 20px; }
.crumbs { margin-bottom: 22px; font-size: 14px; color: var(--muted); }
.crumbs a { text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }

/* usluge — detaljni blokovi */
.svc { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 72px); padding: clamp(56px, 7vw, 96px) 0; border-bottom: 1px solid var(--line); scroll-margin-top: 80px; }
.svc:last-child { border-bottom: 0; }
.svc__photo img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--r); }
.svc .h2 { margin-bottom: 18px; }
.svc p { color: var(--muted); }
.svc ul { margin: 0 0 1em; padding-left: 1.1em; color: var(--muted); }
.svc li { margin-bottom: 6px; }
.toc { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; }
.toc a { padding: 9px 16px; border: 1px solid var(--line); border-radius: 40px; background: #fff; text-decoration: none; font-weight: 500; font-size: 15px; }
.toc a:hover { border-color: var(--ink); }

/* tekstualni blok */
.prose { max-width: 720px; }
.prose h2 { margin: 1.6em 0 .5em; font-size: 28px; }
.prose p, .prose li { color: #34364d; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 88px); align-items: start; }
.split img { width: 100%; border-radius: var(--r); aspect-ratio: 4 / 3; object-fit: cover; }
.photo-row { display: grid; grid-template-columns: 2fr 1fr; gap: 18px; margin-top: 18px; }
.photo-row img { width: 100%; height: 100%; aspect-ratio: auto; object-fit: cover; border-radius: var(--r); }

/* vozni park — tabela vozila */
.vtable { width: 100%; border-collapse: collapse; font-size: 16px; }
.vtable th, .vtable td { padding: 16px 16px 16px 0; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.vtable thead th { font: 600 13px/1 var(--f); letter-spacing: .05em; text-transform: uppercase; color: var(--muted); padding-bottom: 12px; }
.vtable td:first-child { font-weight: 600; }
.vtable td.n { font-variant-numeric: tabular-nums; }
.vwrap { overflow-x: auto; }

/* kontakt */
.contact { display: grid; grid-template-columns: 1.35fr 1fr; gap: clamp(32px, 6vw, 88px); align-items: start; }
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 20px; }
.form fieldset { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; gap: 18px 20px; margin: 0; padding: 0; border: 0; }
.form legend { grid-column: 1 / -1; padding: 18px 0 4px; font: 700 20px/1.2 var(--fc); }
.form fieldset:first-child legend { padding-top: 0; }
.form label { display: flex; flex-direction: column; gap: 7px; font-size: 15px; font-weight: 500; }
.form .full { grid-column: 1 / -1; }
.form input, .form select, .form textarea { width: 100%; padding: 13px 14px; border: 1px solid rgba(22, 23, 43, .25); border-radius: var(--r); background: #fff; font: 400 17px/1.4 var(--f); color: var(--ink); }
.form input:focus, .form select:focus, .form textarea:focus { outline: 2px solid var(--blue); outline-offset: -1px; border-color: var(--blue); }
.form textarea { min-height: 120px; resize: vertical; }
.form .check { flex-direction: row; align-items: flex-start; gap: 10px; font-weight: 400; color: var(--muted); }
.form .check input { width: 18px; height: 18px; margin-top: 3px; flex-shrink: 0; }
.form__ok { display: none; grid-column: 1 / -1; padding: 18px 20px; background: var(--paper); border-left: 3px solid var(--blue); }
.form.sent .form__ok { display: block; }
.card { padding: 30px; background: var(--paper); border-radius: var(--r); }
.card + .card { margin-top: 18px; }
.card h2 { margin-bottom: 16px; font-size: 22px; }
.card p:last-child { margin-bottom: 0; }
.card .big { display: block; font: 700 30px/1.1 var(--fc); text-decoration: none; font-variant-numeric: tabular-nums; }
.map { width: 100%; aspect-ratio: 4 / 3; border: 0; border-radius: var(--r); filter: grayscale(.4); }

/* responsive */
@media (max-width: 1080px) {
  .nav__tel, .lang { display: none; }
  .quick form { grid-template-columns: 1fr 1fr; }
  .quick label { padding: 14px 18px 14px 0; border-right: 0; border-bottom: 1px solid rgba(22, 23, 43, .2); }
  .quick .btn { grid-column: 1 / -1; margin: 16px 0; }
  .fleet__in { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .burger { display: block; margin-left: auto; }
  .hdr__cta { display: none; }
  .nav { position: fixed; inset: 76px 0 0; flex-direction: column; align-items: stretch; gap: 0; padding: 20px 28px; background: #fff; transform: translateX(100%); visibility: hidden; transition: transform .3s, visibility .3s; }
  .nav.open { transform: none; visibility: visible; }
  .nav a { padding: 16px 0; border-bottom: 1px solid var(--line); font: 600 24px/1.2 var(--fc); }
  .nav a[aria-current] { box-shadow: none; color: var(--blue); }
  .nav .nav__tel { display: block; margin: 0; }
  .panel, .base, .svc, .split, .contact { grid-template-columns: 1fr; }
  .cta__in { flex-direction: column; align-items: flex-start; }
  .ftr__grid { grid-template-columns: 1fr 1fr; }
  .marks { grid-template-columns: repeat(2, 1fr); }
  .strip { grid-auto-columns: 78%; }
  .sec__head { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 640px) {
  .wrap { padding: 0 16px; }
  .hero__in { padding: 64px 16px 48px; }
  .hero__img::after { background: linear-gradient(180deg, rgba(22, 23, 43, .55) 0%, rgba(22, 23, 43, .92) 70%); }
  .form, .form fieldset { grid-template-columns: 1fr; }
  .quick label:nth-child(odd) { padding-right: 12px; border-right: 1px solid rgba(22, 23, 43, .2); }
  .quick label:nth-child(even) { padding-left: 12px; }
  .strip { --gut: 16px; padding-right: 16px; }
  .ftr__grid { grid-template-columns: 1fr; }
  .ftr { padding-bottom: 92px; }
  .photo-row { grid-template-columns: 1fr; }
  .mbar { display: grid; grid-template-columns: 1fr 1fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; background: var(--ink); border-top: 1px solid var(--line-lt); }
  .mbar a { padding: 17px 10px; text-align: center; color: #fff; font-weight: 600; text-decoration: none; }
  .mbar a + a { background: var(--yellow); color: var(--ink); }
  .tabs button { padding: 14px 14px 12px; font-size: 17px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
