/* Czcionka Archivo (licencja SIL Open Font License) — pliki lokalne w folderze fonts/. */
@font-face {
  font-family: "Archivo";
  font-style: normal; font-weight: 300 900; font-stretch: 62% 125%; font-display: swap;
  src: url("fonts/archivo-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Archivo";
  font-style: normal; font-weight: 300 900; font-stretch: 62% 125%; font-display: swap;
  src: url("fonts/archivo-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --ink: #101b2d;
  --ink-soft: #4a5567;
  --paper: #ffffff;
  --concrete: #e9ecef;
  --brass: #a8761c;
  --sky: #1b4fd6;
  --sky-pale: #e8effc;
  --line: rgba(16, 27, 45, 0.16);

  --seam: 40%;
  --gutter: clamp(16px, 4vw, 56px);
  --display: "Archivo", "Helvetica Neue", Arial, sans-serif;
}

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

html { scroll-behavior: smooth; scroll-padding-top: 64px; }

body {
  margin: 0;
  font-family: var(--display);
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, p, ul, dl, dd { margin: 0; }
ul { padding: 0; list-style: none; }
a { color: inherit; }

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

.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip-path: inset(50%); white-space: nowrap;
}

.wrap { max-width: 1160px; margin-inline: auto; padding-inline: var(--gutter); }

/* ---------- Pasek górny ---------- */

.topbar {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  height: 64px; padding-inline: var(--gutter);
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

.topbar__logo {
  font-stretch: 125%; font-weight: 800; font-size: 22px; letter-spacing: -0.02em;
  text-decoration: none;
}
.topbar__logo span { color: var(--sky); }

.topbar__nav { display: flex; align-items: center; gap: clamp(14px, 2.4vw, 32px); font-size: 15px; font-weight: 500; }
.topbar__nav a { text-decoration: none; }
.topbar__nav a:hover { text-decoration: underline; text-underline-offset: 5px; }

.topbar__toggle {
  display: none; padding: 8px 16px; border: 1px solid var(--line); border-radius: 999px;
  background: none; color: var(--ink); font: inherit; font-size: 15px; font-weight: 500; cursor: pointer;
}

.topbar__cta {
  padding: 8px 16px; border-radius: 999px;
  background: var(--ink); color: var(--paper);
}
.topbar__nav .topbar__cta:hover { text-decoration: none; background: var(--sky); }

/* ---------- Hero: ziemia | niebo ---------- */

.hero {
  position: relative;
  display: grid; grid-template-columns: var(--seam) 1fr;
  min-height: min(calc(100svh - 64px), 700px);
}

.hero__half {
  display: flex; flex-direction: column; justify-content: flex-start;
  padding-block: clamp(56px, 12vh, 120px) clamp(120px, 22vh, 200px);
  text-decoration: none;
  transition: background-color 0.25s;
}

.hero__half--ground { align-items: flex-end; text-align: right; background: var(--concrete); color: var(--ink); }
.hero__half--sky { align-items: flex-start; background: var(--sky); color: #fff; }
.hero__half--ground:hover { background: #dfe3e7; }
.hero__half--sky:hover { background: #1746c2; }

.hero__word {
  font-stretch: 125%; font-weight: 800;
  font-size: clamp(56px, 12.5vw, 210px);
  line-height: 0.9; letter-spacing: -0.035em;
}

.hero__branch {
  margin-top: clamp(16px, 3vw, 36px);
  font-stretch: 110%; font-weight: 700; font-size: clamp(17px, 2vw, 26px);
  text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 6px;
}
.hero__half--ground .hero__branch { text-decoration-color: var(--brass); }

.hero__desc {
  margin-top: 10px; max-width: 30ch;
  font-size: clamp(14px, 1.25vw, 17px); line-height: 1.5;
  opacity: 0.85;
}

.hero__half--ground > * { padding-right: clamp(6px, 1.2vw, 20px); padding-left: var(--gutter); }
.hero__half--sky > * { padding-left: clamp(6px, 1.2vw, 20px); padding-right: var(--gutter); }
.hero__half > .hero__word { padding-inline: 0; }
.hero__half--ground > .hero__word { padding-right: 0.03em; }
.hero__half--sky > .hero__word { padding-left: 0.03em; }

.hero__path {
  position: absolute; inset: 0; width: 100%; height: 100%;
  pointer-events: none;
}
.hero__path path {
  fill: none; stroke: var(--brass); stroke-width: 3;
  stroke-dasharray: var(--len, none); stroke-dashoffset: var(--len, 0);
}
.hero__path.is-drawn path {
  animation: takeoff 2.4s cubic-bezier(0.5, 0, 0.2, 1) 0.2s forwards;
}
@keyframes takeoff { to { stroke-dashoffset: 0; } }

/* ---------- Wstęp ---------- */

.intro { padding-block: clamp(48px, 7vw, 96px); border-bottom: 1px solid var(--line); }
.intro__grid { display: grid; grid-template-columns: var(--seam) 1fr; gap: 24px; align-items: start; }
.intro h1 {
  font-stretch: 118%; font-weight: 800; font-size: clamp(26px, 3vw, 38px);
  line-height: 1.12; letter-spacing: -0.02em; max-width: 14ch;
}
.intro p { max-width: 58ch; font-size: clamp(18px, 1.6vw, 21px); line-height: 1.5; }

/* ---------- Gałęzie ---------- */

.branch { padding-block: clamp(64px, 10vw, 128px); }
.branch--sky { background: var(--sky-pale); }

.branch__head {
  display: grid; grid-template-columns: var(--seam) 1fr; gap: 20px 24px;
  margin-bottom: clamp(32px, 5vw, 64px);
}
/* Nagłówek zajmuje całą szerokość, żeby długie słowo nie wchodziło na opis obok. */
.branch__head h2 { grid-column: 1 / -1; }
.branch__head p { grid-column: 2; }
.branch__head p { max-width: 56ch; color: var(--ink-soft); font-size: 19px; }

h2 {
  font-stretch: 125%; font-weight: 800;
  font-size: clamp(34px, 5vw, 64px); line-height: 1; letter-spacing: -0.03em;
}
.branch--sky h2 { color: var(--sky); }

.service {
  display: grid; grid-template-columns: var(--seam) 1fr; gap: 24px;
  padding-block: 28px;
  border-top: 1px solid var(--line);
}
.services { border-bottom: 1px solid var(--line); }

.service h3 {
  font-stretch: 112%; font-weight: 700; font-size: clamp(20px, 2vw, 26px);
  line-height: 1.2; letter-spacing: -0.01em; max-width: 16ch;
}
.service p { max-width: 58ch; }
.service__note { margin-top: 8px; color: var(--ink-soft); font-size: 15px; }

.button {
  display: inline-block; margin-top: 40px; margin-left: calc(var(--seam) + 14px);
  padding: 14px 26px; border-radius: 999px;
  font-weight: 600; text-decoration: none; color: #fff;
  transition: background-color 0.2s;
}
.branch__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 40px; margin-left: calc(var(--seam) + 14px); }
.branch__actions .button { margin: 0; }
.button--outline { color: var(--sky); box-shadow: inset 0 0 0 1.5px var(--sky); }
.button--outline:hover { background: var(--sky); color: #fff; }
.button--ground { background: var(--ink); }
.button--ground:hover { background: var(--brass); }
.button--sky { background: var(--sky); }
.button--sky:hover { background: var(--ink); }

/* ---------- Realizacje ---------- */

.gallery { padding-block: clamp(64px, 10vw, 128px) 0; }
.gallery__head {
  display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 20px 32px;
  margin-bottom: clamp(24px, 4vw, 48px);
}

.gallery__filters[hidden] { display: none; }
.gallery__filters { display: flex; flex-wrap: wrap; gap: 8px; }
.gallery__filters button {
  padding: 8px 16px; border: 1px solid var(--line); border-radius: 999px;
  background: none; color: var(--ink); font: inherit; font-size: 15px; font-weight: 500; cursor: pointer;
}
.gallery__filters button:hover { border-color: var(--ink); }
.gallery__filters button[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }

.gallery__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(8px, 1.4vw, 16px); }
.gallery__item { aspect-ratio: 4 / 3; }
.gallery__item[hidden] { display: none; }
/* Pierwsze zdjęcie jest większe: zajmuje dwie kolumny i dwa rzędy. */
.gallery__item:first-child { grid-column: span 2; grid-row: span 2; aspect-ratio: auto; }

.gallery__open {
  display: block; width: 100%; height: 100%; padding: 0; border: 0;
  background: var(--concrete); cursor: zoom-in; overflow: hidden;
}
.gallery__open img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.gallery__open:hover img { transform: scale(1.03); }

.gallery__item.is-empty .gallery__open {
  display: grid; place-items: center; padding: 16px;
  border: 1px dashed var(--line); background: none; cursor: default;
  font: inherit; font-size: 14px; color: var(--ink-soft); overflow-wrap: anywhere;
}
.gallery__item[data-branch="lotnictwo"].is-empty .gallery__open { background: var(--sky-pale); }

.lightbox {
  width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0;
  background: rgba(16, 27, 45, 0.94);
}
.lightbox[open] { display: grid; place-items: center; }
.lightbox::backdrop { background: none; }
.lightbox img { max-width: calc(100vw - 32px); max-height: calc(100dvh - 120px); object-fit: contain; }
.lightbox button {
  position: absolute; width: 48px; height: 48px; border: 0; border-radius: 50%;
  background: rgba(255, 255, 255, 0.14); color: #fff; font-size: 28px; line-height: 1; cursor: pointer;
}
.lightbox button:hover { background: rgba(255, 255, 255, 0.3); }
.lightbox :focus-visible { outline-color: #fff; }
.lightbox__close { top: 16px; right: 16px; }
.lightbox__nav { bottom: 16px; }
.lightbox__nav--prev { left: calc(50% - 56px); }
.lightbox__nav--next { left: calc(50% + 8px); }

/* ---------- O firmie ---------- */

.about { padding-block: clamp(64px, 10vw, 128px); }
.about__grid { display: grid; grid-template-columns: var(--seam) 1fr; gap: 24px; }
.about h2 { font-size: clamp(28px, 3.6vw, 46px); max-width: 10ch; }
.about__text p { max-width: 62ch; color: var(--ink-soft); }
.about__text p + p { margin-top: 14px; }
.about__text .about__lead { font-size: 21px; line-height: 1.45; color: var(--ink); }
.about__text h3 {
  margin-top: 40px; margin-bottom: 12px; max-width: 28ch;
  font-stretch: 112%; font-weight: 700; font-size: clamp(20px, 2vw, 24px); line-height: 1.25;
}

/* ---------- Pytania ---------- */

.faq { padding-block: 0 clamp(64px, 10vw, 128px); }
.faq h2 { font-size: clamp(28px, 3.6vw, 46px); max-width: 10ch; }
.faq__list { border-bottom: 1px solid var(--line); }
.faq details { border-top: 1px solid var(--line); }
.faq summary {
  display: flex; justify-content: space-between; align-items: baseline; gap: 16px;
  padding-block: 18px; cursor: pointer; list-style: none;
  font-stretch: 108%; font-weight: 600; font-size: 18px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-weight: 400; font-size: 24px; line-height: 1; color: var(--ink-soft); }
.faq details[open] summary::after { content: "–"; }
.faq details p { max-width: 62ch; padding-bottom: 20px; color: var(--ink-soft); }

/* ---------- Kontakt ---------- */

.contact { padding-block: clamp(64px, 10vw, 112px); background: var(--ink); color: #fff; }
.contact__grid { display: grid; grid-template-columns: var(--seam) 1fr; gap: 24px; }
.contact__lead { margin-top: 20px; max-width: 34ch; color: rgba(255, 255, 255, 0.72); }

.contact__list > div {
  display: grid; grid-template-columns: 110px 1fr; gap: 16px; align-items: baseline;
  padding-block: 20px; border-top: 1px solid rgba(255, 255, 255, 0.2);
}
.contact__list > div:last-child { border-bottom: 1px solid rgba(255, 255, 255, 0.2); }
.contact__list dt { font-size: 15px; color: rgba(255, 255, 255, 0.6); }
.contact__list dd { font-stretch: 112%; font-weight: 600; font-size: clamp(19px, 2.2vw, 28px); line-height: 1.3; }
.contact__list a { text-decoration: none; }
.contact__list a:hover { text-decoration: underline; text-underline-offset: 6px; }
.contact :focus-visible { outline-color: #fff; }

.contact__list dd { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 20px; }
.contact__name { min-width: 5.5em; }

.phone {
  white-space: nowrap;
  padding: 6px 18px; border: 1px solid rgba(255, 255, 255, 0.5); border-radius: 999px;
  background: none; color: inherit; font: inherit; font-size: 16px; cursor: pointer;
  transition: background-color 0.2s, color 0.2s;
}
.phone:hover { background: #fff; color: var(--ink); }

/* ---------- Stopka ---------- */

.footer { background: var(--ink); color: rgba(255, 255, 255, 0.6); font-size: 14px; padding-block: 24px 32px; }
.footer__grid { display: flex; flex-wrap: wrap; gap: 6px 32px; }
.footer__grid p:last-child { margin-left: auto; }

/* ---------- Małe ekrany ---------- */

@media (max-width: 760px) {
  .topbar__toggle { display: block; }
  .topbar__nav {
    display: none; position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    padding: 8px var(--gutter) 20px;
    background: var(--paper); border-bottom: 1px solid var(--line);
    font-size: 18px;
  }
  .topbar__nav.is-open { display: flex; }
  .topbar__nav a { padding-block: 12px; border-bottom: 1px solid var(--line); }
  .topbar__nav .topbar__cta { margin-top: 16px; padding: 12px 16px; border: 0; text-align: center; }

  .gallery__grid { grid-template-columns: repeat(2, 1fr); }
  .branch__head p { grid-column: 1; }
  .branch__head, .service, .about__grid, .contact__grid, .intro__grid { grid-template-columns: 1fr; gap: 12px; }
  .intro h1, .faq h2, .about h2 { max-width: none; }
  .service h3 { max-width: none; }
  .button, .branch__actions { margin-left: 0; }
  .contact__list { margin-top: 16px; }
  .contact__list > div { grid-template-columns: 110px 1fr; }
  .hero { min-height: 480px; }
}

@media (max-width: 520px) {
  .hero__desc { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero__path.is-drawn path { animation: none; stroke-dasharray: none; }
  .hero__half, .button, .gallery__open img { transition: none; }
}
