/* ==========================================================================
   Metal Art — EN
   Palette taken from the company mark: deep red #8E2025, brass #D1AC66.
   Greys are cold on purpose — the subject is steel, not paper.
   ========================================================================== */

:root {
  --ink:      #14171a;
  --ink-soft: #2b3037;
  --slate:    #5a6470;
  --slate-lt: #8d97a3;
  --mill:     #e4e6e9;
  --mill-lt:  #f1f2f4;
  --paper:    #fbfbfc;
  --white:    #ffffff;
  --red:      #8e2025;
  --red-dark: #6f181c;
  --brass:    #d1ac66;

  --shell: 1240px;
  --gut:   clamp(1.25rem, 4vw, 3rem);

  --sans:    "Public Sans", "Segoe UI", system-ui, -apple-system, sans-serif;
  --display: "Archivo", "Public Sans", system-ui, sans-serif;

  --step--1: clamp(0.82rem, 0.79rem + 0.13vw, 0.89rem);
  --step-0:  clamp(1rem, 0.96rem + 0.2vw, 1.12rem);
  --step-1:  clamp(1.2rem, 1.12rem + 0.38vw, 1.45rem);
  --step-2:  clamp(1.45rem, 1.3rem + 0.72vw, 1.95rem);
  --step-3:  clamp(1.8rem, 1.5rem + 1.4vw, 2.75rem);
  --step-4:  clamp(2.2rem, 1.6rem + 2.9vw, 4.25rem);
}

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

html {
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  scroll-padding-top: calc(env(safe-area-inset-top, 0px) + 5rem);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--step-0);
  line-height: 1.62;
  font-synthesis-weight: none;
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
}

img, svg, video { max-width: 100%; height: auto; display: block; }

a { color: inherit; }

:focus-visible {
  outline: 3px solid var(--red);
  outline-offset: 3px;
}

::selection { background: var(--brass); color: var(--ink); }

.skip {
  position: absolute;
  left: -9999px;
  z-index: 100;
  padding: 0.8rem 1.4rem;
  background: var(--red);
  color: var(--white);
  font-weight: 600;
  text-decoration: none;
}

.skip:focus { left: 0; top: 0; }

/* -------------------------------------------------------------- typography */

h1, h2, h3, h4 {
  font-family: var(--display);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.021em;
  margin: 0 0 0.6em;
  text-wrap: balance;
}

h1 { font-size: var(--step-4); font-weight: 800; letter-spacing: -0.03em; }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-1); letter-spacing: -0.012em; }
h4 { font-size: var(--step-0); letter-spacing: 0; }

p  { margin: 0 0 1.15em; max-width: 68ch; }
p:last-child { margin-bottom: 0; }

.lede {
  font-size: var(--step-1);
  line-height: 1.5;
  color: var(--ink-soft);
  max-width: 56ch;
}

strong { font-weight: 650; }

.num { font-variant-numeric: tabular-nums; font-feature-settings: "tnum" 1; }

/* ------------------------------------------------------------------ layout */

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

.band { padding-block: clamp(3.5rem, 7vw, 6.5rem); }
.band--tight { padding-block: clamp(2.5rem, 4.5vw, 4rem); }
.band--mill  { background: var(--mill-lt); }
.band--ink   { background: var(--ink); color: var(--mill); }
.band--ink h2, .band--ink h3 { color: var(--white); }

.rule-top { border-top: 1px solid var(--mill); }

/* ------------------------------------------------------------------ header */

.masthead {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 60;
  background: var(--white);
  border-bottom: 1px solid var(--mill);
}

.masthead__in {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  min-height: 4.5rem;
}

.brand { flex: 0 0 auto; line-height: 0; }
.brand img { width: 168px; }

.nav { margin-left: auto; }

.nav__list {
  display: flex;
  align-items: center;
  gap: clamp(0.35rem, 1.4vw, 1.6rem);
  list-style: none;
  margin: 0; padding: 0;
}

.nav__link {
  display: inline-block;
  padding: 0.5rem 0.25rem;
  font-size: var(--step--1);
  font-weight: 550;
  letter-spacing: 0.005em;
  text-decoration: none;
  color: var(--ink-soft);
  border-bottom: 2px solid transparent;
}

.nav__link:hover { color: var(--red); }
.nav__link[aria-current="page"] { color: var(--red); border-bottom-color: var(--red); }

.nav__drop { position: relative; }

.nav__panel {
  position: absolute;
  top: 100%; left: -1rem;
  min-width: 17rem;
  background: var(--white);
  border: 1px solid var(--mill);
  border-top: 2px solid var(--red);
  padding: 0.4rem;
  list-style: none;
  margin: 0;
  display: none;
  box-shadow: 0 14px 34px -20px rgba(20, 23, 26, 0.5);
}

.nav__drop:hover .nav__panel,
.nav__drop:focus-within .nav__panel { display: block; }

.nav__panel a {
  display: block;
  padding: 0.5rem 0.75rem;
  font-size: var(--step--1);
  text-decoration: none;
  color: var(--ink-soft);
}

.nav__panel a:hover { background: var(--mill-lt); color: var(--red); }

.langs {
  display: flex; gap: 0.5rem;
  margin-left: 0.5rem;
  padding-left: 1rem;
  border-left: 1px solid var(--mill);
  font-size: var(--step--1);
  font-weight: 600;
}

.langs a { text-decoration: none; color: var(--slate-lt); }
.langs a:hover { color: var(--ink); }
.langs [aria-current] { color: var(--ink); }

.navtoggle {
  display: none;
  margin-left: auto;
  background: none;
  border: 1px solid var(--mill);
  padding: 0.55rem 0.8rem;
  font: inherit;
  font-size: var(--step--1);
  font-weight: 600;
  cursor: pointer;
}

/* --------------------------------------------------------------------- hero */

.hero { position: relative; background: var(--ink); overflow: hidden; }

.hero__img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0.42;
  filter: grayscale(0.25) contrast(1.05);
}

.hero__in {
  position: relative;
  padding-block: clamp(5rem, 13vw, 10.5rem);
  color: var(--white);
}

.hero h1 { color: var(--white); max-width: 17ch; margin-bottom: 0.45em; }

.hero__sub {
  font-size: var(--step-1);
  line-height: 1.45;
  color: #d2d6db;
  max-width: 48ch;
  margin-bottom: 2rem;
}

/* Dugmad u hero sekciji. Na telefonu idu jedno ispod drugog, po celoj sirini
   do razumne mere, sa pravim razmakom. Na sirem ekranu stoje jedno pored
   drugog. Ranije su bila inline sa levom marginom, pa je prelamanjem drugo
   dugme ispadalo uvuceno udesno. */
.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 1.1rem;
  align-items: center;
}

.hero__cta .btn { text-align: center; }

@media (max-width: 34rem) {
  .hero__cta { flex-direction: column; align-items: stretch; gap: 1.6rem; }
  .hero__cta .btn { width: 100%; max-width: 22rem; }
}

.hero--page .hero__in { padding-block: clamp(3.5rem, 8vw, 6rem); }
.hero--page h1 { font-size: var(--step-3); max-width: 20ch; }

/* ------------------------------------------------------------- spec strip */

.specstrip { background: var(--ink-soft); }

.specstrip__list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  list-style: none; margin: 0; padding: 0;
}

.specstrip__item {
  padding: 1.35rem 1.5rem 1.4rem 0;
  border-left: 1px solid rgba(255, 255, 255, 0.14);
  padding-left: 1.5rem;
}

.specstrip__item:first-child { border-left: 0; padding-left: 0; }

.specstrip__k {
  display: block;
  font-size: 0.78rem;
  color: var(--slate-lt);
  margin-bottom: 0.3rem;
}

.specstrip__v {
  display: block;
  font-family: var(--display);
  font-size: var(--step-1);
  font-weight: 700;
  color: var(--white);
  letter-spacing: -0.015em;
}

.specstrip__v .u {
  font-weight: 400;
  font-size: 0.72em;
  color: #b6bdc6;
  margin-left: 0.2em;
}

/* -------------------------------------------------------------- components */

.btn {
  display: inline-block;
  padding: 0.85rem 1.7rem;
  background: var(--red);
  color: var(--white);
  font-weight: 600;
  font-size: var(--step-0);
  text-decoration: none;
  border: 1px solid var(--red);
  transition: background 0.15s ease;
}

.btn:hover { background: var(--red-dark); border-color: var(--red-dark); }

.btn--ghost {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.45);
}

.btn--ghost:hover { background: rgba(255, 255, 255, 0.1); border-color: var(--white); }

.hdg-rule::after {
  content: "";
  display: block;
  width: 3.5rem;
  height: 3px;
  background: var(--brass);
  margin-top: 1.1rem;
}

/* service grid — each tile carries one hard number, not decoration */

.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr));
  gap: 1px;
  background: var(--mill);
  border: 1px solid var(--mill);
}

.tile {
  display: flex;
  flex-direction: column;
  background: var(--white);
  text-decoration: none;
  color: inherit;
}

.tile:hover .tile__name { color: var(--red); }
.tile:hover .tile__shot img { transform: scale(1.03); }

.tile__shot { aspect-ratio: 16 / 10; overflow: hidden; background: var(--mill); }
.tile__shot img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }

.tile__body { padding: 1.2rem 1.3rem 1.4rem; flex: 1; display: flex; flex-direction: column; }

.tile__name {
  font-family: var(--display);
  font-weight: 700;
  font-size: var(--step-1);
  letter-spacing: -0.012em;
  margin-bottom: 0.35rem;
}

.tile__note { font-size: var(--step--1); color: var(--slate); margin-bottom: 1rem; }

.tile__spec {
  margin-top: auto;
  padding-top: 0.8rem;
  border-top: 1px solid var(--mill);
  font-size: var(--step--1);
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}

.tile__spec b { font-weight: 650; }

/* datasheet table */

.sheet { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.sheet caption { text-align: left; font-weight: 650; padding-bottom: 0.7rem; }
.sheet th, .sheet td { text-align: left; padding: 0.7rem 1rem 0.7rem 0; border-bottom: 1px solid var(--mill); }
.sheet th { font-weight: 550; color: var(--slate); width: 46%; }
.sheet td { font-weight: 600; }
.sheet tr:last-child th, .sheet tr:last-child td { border-bottom: 0; }

.scroll-x { overflow-x: auto; }

/* two-column prose + aside */

.split {
  display: grid;
  gap: clamp(2rem, 5vw, 4.5rem);
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  align-items: start;
}

.split--even { grid-template-columns: repeat(auto-fit, minmax(19rem, 1fr)); }

.panel { background: var(--white); border: 1px solid var(--mill); padding: clamp(1.4rem, 3vw, 2.1rem); }
.band--ink .panel { background: #1d2126; border-color: #2e343b; }

/* facts list */

.facts { list-style: none; margin: 0; padding: 0; display: grid; gap: 1px; background: var(--mill); }
.band--ink .facts { background: #2e343b; }

.facts li { background: var(--white); padding: 1rem 0 1rem 1.15rem; border-left: 3px solid var(--brass); }
.band--ink .facts li { background: var(--ink); }

.facts b { font-family: var(--display); font-weight: 700; font-size: var(--step-1); display: block; letter-spacing: -0.015em; }
.facts span { font-size: var(--step--1); color: var(--slate); }
.band--ink .facts span { color: var(--slate-lt); }

/* certificate row */

.certs { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); }

.cert {
  border: 1px solid var(--mill);
  background: var(--white);
  padding: 1.3rem 1.4rem;
}

.cert__std { font-family: var(--display); font-weight: 700; font-size: var(--step-1); letter-spacing: -0.015em; margin-bottom: 0.3rem; }
.cert__by  { font-size: var(--step--1); color: var(--slate); }

/* gallery */

.gallery { display: grid; gap: 2px; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); }

.gallery__item {
  display: block;
  position: relative;
  padding: 0;
  margin: 0;
  border: 0;
  background: var(--mill);
  cursor: zoom-in;
  overflow: hidden;
}

.gallery img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: var(--mill); }

.gallery__item img { transition: transform 0.35s ease; }
.gallery__item:hover img { transform: scale(1.04); }

.gallery__item::after {
  content: "";
  position: absolute;
  inset: auto 0.55rem 0.55rem auto;
  width: 1.9rem; height: 1.9rem;
  background: rgba(20, 23, 26, 0.72) center / 0.85rem no-repeat
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M9 3H3v6M15 3h6v6M9 21H3v-6M15 21h6v-6'/%3E%3C/svg%3E");
  opacity: 0;
  transition: opacity 0.2s ease;
}

.gallery__item:hover::after,
.gallery__item:focus-visible::after { opacity: 1; }

/* lightbox */

.lb {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(10, 12, 14, 0.94);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: calc(env(safe-area-inset-top, 0px) + 3.5rem) 1rem
           calc(env(safe-area-inset-bottom, 0px) + 3.5rem);
}

.lb[hidden] { display: none; }

.lb__stage {
  margin: 0;
  max-width: min(1400px, 100%);
  max-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.9rem;
}

.lb__img {
  max-width: 100%;
  max-height: calc(100vh - 11rem);
  width: auto;
  object-fit: contain;
  background: var(--ink-soft);
}

.lb__cap {
  color: #b6bdc6;
  font-size: var(--step--1);
  text-align: center;
  max-width: 62ch;
}

.lb__x,
.lb__nav {
  position: absolute;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.24);
  color: #fff;
  cursor: pointer;
  font: inherit;
  line-height: 1;
  transition: background 0.15s ease;
}

.lb__x:hover,
.lb__nav:hover { background: rgba(255, 255, 255, 0.22); }

.lb__x {
  top: calc(env(safe-area-inset-top, 0px) + 0.9rem);
  right: 0.9rem;
  width: 2.75rem; height: 2.75rem;
  font-size: 1.7rem;
}

.lb__nav {
  top: 50%;
  transform: translateY(-50%);
  width: 3rem; height: 4.5rem;
  font-size: 2.2rem;
}

.lb__nav--prev { left: 0.6rem; }
.lb__nav--next { right: 0.6rem; }

@media (max-width: 48rem) {
  .lb__nav { width: 2.5rem; height: 3.6rem; font-size: 1.8rem; }
  .lb__img { max-height: calc(100vh - 13rem); }
}

/* faq */

.qa { border-top: 1px solid var(--mill); padding-top: 1.4rem; margin-top: 1.4rem; }
.qa:first-of-type { border-top: 0; padding-top: 0; margin-top: 0; }
.qa h3 { margin-bottom: 0.4rem; }
.qa p { color: var(--ink-soft); }

/* ------------------------------------------------------------------ footer */

.foot { background: var(--ink); color: var(--slate-lt); padding-block: clamp(3rem, 6vw, 4.5rem) 2rem; font-size: var(--step--1); }
.foot a { color: var(--mill); text-decoration: none; }
.foot a:hover { color: var(--white); text-decoration: underline; }
.foot h4 { color: var(--white); font-size: var(--step--1); font-weight: 650; margin-bottom: 0.9rem; letter-spacing: 0.01em; }
.foot ul { list-style: none; margin: 0; padding: 0; }
.foot li { margin-bottom: 0.45rem; }

.foot__grid { display: grid; gap: 2.5rem; grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); }
.foot__mark { width: 150px; background: var(--white); padding: 0.55rem 0.7rem; margin-bottom: 1.1rem; }

.foot__base {
  margin-top: 3rem; padding-top: 1.5rem;
  border-top: 1px solid #2e343b;
  display: flex; flex-wrap: wrap; gap: 0.6rem 2rem; align-items: baseline;
  color: #79828d;
}

.foot__by { margin-left: auto; }
.foot__by a { color: #9aa3ad; text-decoration: none; border-bottom: 1px solid #3c434b; }
.foot__by a:hover { color: var(--brass); border-bottom-color: var(--brass); text-decoration: none; }

@media (max-width: 48rem) {
  .foot__by { margin-left: 0; }
}

/* ------------------------------------------------------------------ mobile */

@media (max-width: 62rem) {
  .navtoggle { display: block; }
  .nav {
    display: none; width: 100%;
    order: 3;
    padding-block: 0.5rem 1.25rem;
    border-top: 1px solid var(--mill);
  }
  .masthead__in { flex-wrap: wrap; }
  .masthead.is-open .nav { display: block; }
  .nav__list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav__link { padding: 0.7rem 0; border-bottom: 1px solid var(--mill-lt); }
  .nav__link[aria-current="page"] { border-bottom-color: var(--red); }
  .nav__panel { position: static; display: block; border: 0; border-left: 2px solid var(--mill); box-shadow: none; padding: 0 0 0 0.9rem; margin-bottom: 0.5rem; }
  .langs { border-left: 0; padding-left: 0; margin: 0.9rem 0 0; }
  .split { grid-template-columns: 1fr; }
}

@media (max-width: 48rem) {
  .specstrip__list { grid-template-columns: repeat(2, 1fr); }
  .specstrip__item:nth-child(3) { border-left: 0; padding-left: 0; }
  .specstrip__item { padding-block: 1rem; }
  .brand img { width: 138px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* --------------------------------------------------------- kontakt forma */

.form { margin-top: 2.5rem; max-width: 60rem; }

.form__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem 2rem;
}
.field--wide { grid-column: 1 / -1; }

.field { display: flex; flex-direction: column; gap: 0.45rem; }

.field label {
  font-size: var(--step--1);
  font-weight: 600;
  color: var(--ink-soft);
  letter-spacing: 0.01em;
}
.req {
  color: var(--red);
  text-decoration: none;
  border: 0;
  font-weight: 700;
  cursor: help;
}

.field input, .field textarea {
  font: inherit;
  font-size: var(--step-0);
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--mill);
  border-bottom-width: 2px;
  border-radius: 0;
  padding: 0.75rem 0.9rem;
  width: 100%;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
  -webkit-appearance: none;
  appearance: none;
}
.field textarea { resize: vertical; min-height: 9rem; line-height: 1.55; }

.field input:hover, .field textarea:hover { border-color: var(--slate-lt); }
.field input:focus, .field textarea:focus {
  outline: 0;
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(142, 32, 37, 0.14);
}
.field input:user-invalid, .field textarea:user-invalid { border-bottom-color: var(--red); }

.hint { font-size: var(--step--1); color: var(--slate); line-height: 1.45; }
.hint--warn { color: var(--red); font-weight: 600; }

/* prilog */
.drop {
  position: relative;
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  background: var(--white);
  border: 1px dashed var(--slate-lt);
  padding: 1rem 1.1rem;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.drop input[type="file"] {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}
.drop__btn {
  flex: 0 0 auto;
  font-size: var(--step--1);
  font-weight: 650;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  background: var(--ink);
  color: var(--white);
  padding: 0.6rem 1.1rem;
}
.drop__name {
  font-size: var(--step--1);
  color: var(--slate);
  overflow-wrap: anywhere;
}
.drop:hover, .drop.is-over { border-color: var(--ink); background: var(--mill-lt); }
.drop input[type="file"]:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.drop.is-set { border-style: solid; border-color: var(--ink); }
.drop.is-set .drop__name { color: var(--ink); font-weight: 600; }

.form__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.4rem 2rem;
  margin-top: 2.2rem;
}
.form__note {
  font-size: var(--step--1);
  color: var(--slate);
  max-width: 44ch;
  line-height: 1.5;
  margin: 0;
}
.form__foot .btn { flex: 0 0 auto; }
.btn[disabled] { opacity: 0.55; cursor: progress; }

/* honeypot: covek ga ne vidi i ne moze da dodje do njega tabom */
.form__trap {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* poruke posle slanja */
.msg {
  margin-top: 2rem;
  padding: 1.25rem 1.5rem;
  border-left: 4px solid var(--ink);
  background: var(--white);
}
.msg--ok  { border-left-color: #1d6b3e; }
.msg--err { border-left-color: var(--red); }
.msg__t { font-weight: 650; font-size: var(--step-1); line-height: 1.35; }
.msg__alt { margin-top: 0.5rem; font-size: var(--step--1); color: var(--slate); }

/* ------------------------------------------------------------------- mapa */

.mapbox {
  margin-top: 2rem;
  position: relative;
  background: var(--mill-lt);
  border: 1px solid var(--mill);
  aspect-ratio: 16 / 9;
  max-height: 30rem;
}
.mapbox__ask {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.1rem;
  text-align: center;
  padding: 1.5rem;
  background:
    repeating-linear-gradient(45deg, var(--mill-lt) 0 12px, var(--mill) 12px 13px);
}
.mapbox.is-on { aspect-ratio: auto; border-color: var(--mill); }
.mapbox iframe { display: block; width: 100%; height: 30rem; border: 0; }

@media (max-width: 52rem) {
  .form__grid { grid-template-columns: 1fr; }
  .form__foot { flex-direction: column; align-items: stretch; }
  .form__foot .btn { width: 100%; }
  .form__note { max-width: none; }
  .mapbox { aspect-ratio: 4 / 5; max-height: none; }
  .mapbox iframe { height: 24rem; }
}

/* ------------------------------------------------------------------ print */

@media print {
  .masthead, .foot, .btn { display: none; }
  body { background: #fff; }
}
