/* =========================================================================
   F.U.H. INSTALATOR — Mariusz Misielak (Debica)
   Single-page. Trust & Authority, type-led. Fraunces + Hanken Grotesk.
   Paleta: stalowy petrol (woda) + miedziany plomien (gaz/cieplo) na off-white.
   ========================================================================= */

/* ---------- Fonts ---------- */
@font-face { font-family: 'fallback-serif'; src: local('Georgia'); size-adjust: 96%; ascent-override: 92%; }

:root {
  /* paleta */
  --ink:        #14252A;   /* glowny tekst / petrol-ink */
  --steel:      #12333A;   /* marka / glebokie petrol */
  --steel-700:  #1B4750;
  --steel-600:  #245A66;
  --muted:      #5B6B70;   /* tekst drugorzedny (>=4.5:1 na bg) */
  --flame:      #C2410C;   /* akcent: miedz / plomien gazu */
  --flame-700:  #9A3412;
  --flame-100:  #FBEAE0;
  --bg:         #F6F4F0;   /* off-white, cieply */
  --surface:    #FFFFFF;
  --surface-2:  #EFEDE7;
  --line:       #DFDBD2;
  --line-2:     #CFCABF;
  --ok:         #15734F;
  --ring:       #C2410C;

  /* typografia */
  --font-display: 'Fraunces', 'fallback-serif', Georgia, 'Times New Roman', serif;
  --font-body:    'Hanken Grotesk', system-ui, -apple-system, 'Segoe UI', sans-serif;

  /* skala / rytm */
  --maxw: 1180px;
  --gap: clamp(1rem, 3vw, 2rem);
  --radius: 14px;
  --radius-sm: 10px;
  --shadow-1: 0 1px 2px rgba(20,37,42,.06), 0 6px 18px -8px rgba(20,37,42,.14);
  --shadow-2: 0 10px 40px -16px rgba(20,37,42,.28);
  --header-h: 68px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; padding: 0; }
:focus-visible { outline: 3px solid var(--ring); outline-offset: 2px; border-radius: 4px; }
.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 200;
  background: var(--steel); color: #fff; padding: .7rem 1.1rem; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

/* svg-ikony: bazowy rozmiar (siatka bezpieczenstwa) */
.ico { width: 1.25em; height: 1.25em; flex: none; stroke: currentColor; fill: none;
  stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }

.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: clamp(1.1rem, 4vw, 2.2rem); }
.tnum { font-variant-numeric: tabular-nums; }

/* ---------- Typografia naglowkow ---------- */
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; line-height: 1.08;
  letter-spacing: -.012em; color: var(--steel); font-optical-sizing: auto; }
h2 { font-size: clamp(1.7rem, 1rem + 2.8vw, 2.75rem); }
h3 { font-size: 1.22rem; line-height: 1.2; letter-spacing: -.005em; }
.eyebrow {
  font-family: var(--font-body); font-weight: 700; font-size: .8rem;
  letter-spacing: .14em; text-transform: uppercase; color: var(--flame-700);
  display: inline-flex; align-items: center; gap: .55rem;
}
.eyebrow::before { content:""; width: 26px; height: 2px; background: var(--flame); display:inline-block; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 60ch; }

.section { padding: clamp(3.4rem, 7vw, 6rem) 0; }
.section--tint { background: var(--surface-2); border-block: 1px solid var(--line); }
.section__head { max-width: 56ch; margin-bottom: clamp(1.8rem, 4vw, 2.8rem); }
.section__head p { margin-top: .9rem; color: var(--muted); font-size: 1.08rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .6rem; white-space: nowrap;
  font-family: var(--font-body); font-weight: 700; font-size: 1rem;
  padding: .85rem 1.4rem; border-radius: 999px; border: 1.5px solid transparent;
  cursor: pointer; transition: transform .15s ease, background .2s ease, box-shadow .2s ease, color .2s ease;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--flame); color: #fff; box-shadow: 0 8px 20px -10px rgba(154,52,18,.7); }
.btn--primary:hover { background: var(--flame-700); }
.btn--ghost { background: transparent; color: var(--steel); border-color: var(--line-2); }
.btn--ghost:hover { background: var(--surface); border-color: var(--steel-600); }
.btn--on-steel { background: #fff; color: var(--steel); }
.btn--on-steel:hover { background: var(--flame-100); }
.btn .ico { width: 1.15em; height: 1.15em; }

/* ============================ HEADER ============================ */
.header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(246,244,240,.86);
  backdrop-filter: saturate(150%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.header__inner { display: flex; align-items: center; gap: 1.5rem; height: var(--header-h); }
.brand { display: flex; align-items: center; gap: .65rem; flex: none; }
.brand__mark { width: 38px; height: 38px; }
.brand__txt { display: flex; flex-direction: column; line-height: 1; }
.brand__name { font-family: var(--font-display); font-weight: 600; font-size: 1.12rem; color: var(--steel); letter-spacing: -.01em; }
.brand__sub { font-size: .68rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin-top: .18rem; }

.nav { margin-left: auto; }
.nav__list { display: flex; align-items: center; gap: .35rem; }
.nav__list a {
  display: inline-block; padding: .5rem .7rem; border-radius: 8px;
  font-weight: 600; font-size: .96rem; color: var(--ink); white-space: nowrap;
  transition: background .15s ease, color .15s ease;
}
.nav__list a:hover { background: var(--surface); color: var(--steel); }
.nav__list a.is-active { color: var(--flame-700); background: var(--flame-100); }
.header__cta { display: flex; align-items: center; gap: .6rem; margin-left: .4rem; }
.tel-link {
  display: inline-flex; align-items: center; gap: .5rem; font-weight: 700;
  color: var(--steel); padding: .5rem .8rem; border-radius: 999px; white-space: nowrap;
  border: 1.5px solid var(--line-2); transition: border-color .15s, background .15s;
}
.tel-link:hover { border-color: var(--flame); background: var(--flame-100); }
.tel-link .ico { color: var(--flame); }

.burger { display: none; width: 46px; height: 46px; align-items: center; justify-content: center;
  background: var(--surface); border: 1.5px solid var(--line-2); border-radius: 12px; cursor: pointer; color: var(--steel); }
.burger .ico { width: 24px; height: 24px; }

/* ============================ HERO ============================ */
.hero { position: relative; padding: clamp(3rem, 7vw, 5.5rem) 0 clamp(2.6rem, 5vw, 4rem); overflow: hidden; }
.hero::before {
  content:""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(60% 50% at 88% 0%, rgba(194,65,12,.07), transparent 60%),
    radial-gradient(55% 60% at 6% 100%, rgba(18,51,58,.07), transparent 60%);
}
.hero__grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(1.6rem, 4vw, 3.2rem); align-items: center; }
.hero h1 { font-size: clamp(2.3rem, 1rem + 5vw, 4.1rem); letter-spacing: -.022em; }
.hero h1 .accent { color: var(--flame); font-style: italic; }
.hero__lead { margin-top: 1.2rem; font-size: clamp(1.08rem, 1rem + .5vw, 1.28rem); color: #38484C; max-width: 50ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.8rem; }
.hero__trust { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 2rem; }
.pill {
  display: inline-flex; align-items: center; gap: .5rem; font-weight: 600; font-size: .9rem;
  color: var(--steel); background: var(--surface); border: 1px solid var(--line);
  padding: .5rem .9rem; border-radius: 999px; box-shadow: var(--shadow-1);
}
.pill .ico { width: 1.05em; height: 1.05em; color: var(--flame); }

/* karta-spec obok hero (tabliczka znamionowa, nie zdjecie) */
.hero__card {
  background: var(--steel); color: #E9F0F1; border-radius: var(--radius);
  padding: 1.7rem 1.6rem; box-shadow: var(--shadow-2); position: relative; overflow: hidden;
}
.hero__card::after { content:""; position:absolute; right:-40px; top:-40px; width:160px; height:160px;
  border-radius:50%; background: radial-gradient(circle, rgba(194,65,12,.35), transparent 68%); }
.hero__card h2 { color: #fff; font-size: 1.35rem; }
.spec-list { margin-top: 1.1rem; display: grid; gap: .9rem; }
.spec { display: flex; gap: .8rem; align-items: flex-start; }
.spec .ico { color: #F4B58C; margin-top: .15rem; }
.spec b { color: #fff; font-weight: 700; display: block; font-size: .98rem; }
.spec span { color: #B9C9CC; font-size: .9rem; }
.hero__cardfoot { margin-top: 1.4rem; padding-top: 1.1rem; border-top: 1px solid rgba(255,255,255,.14);
  display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.hero__cardfoot .label { font-size: .8rem; color: #9FB3B6; letter-spacing:.05em; text-transform: uppercase; }
.hero__cardfoot .num { font-family: var(--font-display); font-size: 1.5rem; color: #fff; }

/* ---------- Pas obszaru / zasieg ---------- */
.areastrip { background: var(--steel); color: #DCE6E7; }
.areastrip .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: .7rem 1.4rem; padding-block: .95rem; }
.areastrip .lbl { font-weight: 700; color: #fff; display: inline-flex; align-items: center; gap: .5rem; }
.areastrip .lbl .ico { color: #F4B58C; }
.areastrip ul { display: flex; flex-wrap: wrap; gap: .5rem .65rem; }
.areastrip li { font-size: .92rem; }
.areastrip li::after { content: "·"; margin-left: .65rem; color: #5E7A7F; }
.areastrip li:last-child::after { content: ""; }

/* ============================ USLUGI ============================ */
.svc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.1rem; }
.svc {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.5rem 1.5rem 1.4rem; box-shadow: var(--shadow-1);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.svc:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); border-color: var(--line-2); }
.svc__icon {
  width: 50px; height: 50px; border-radius: 12px; display: grid; place-items: center;
  background: var(--flame-100); color: var(--flame-700); margin-bottom: 1rem;
}
.svc__icon .ico { width: 26px; height: 26px; stroke-width: 1.7; }
.svc h3 { margin-bottom: .5rem; }
.svc p { color: var(--muted); font-size: .99rem; }
.svc__list { margin-top: .9rem; display: grid; gap: .45rem; }
.svc__list li { display: flex; gap: .55rem; align-items: flex-start; font-size: .94rem; color: var(--ink); }
.svc__list .ico { width: 1.05em; height: 1.05em; color: var(--ok); margin-top: .28rem; }

/* ============================ DLACZEGO MY ============================ */
.why-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.why {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.4rem 1.3rem; box-shadow: var(--shadow-1); display: flex; flex-direction: column; gap: .7rem;
}
.why__icon { width: 44px; height: 44px; border-radius: 10px; display: grid; place-items: center;
  background: var(--steel); color: #F4B58C; }
.why__icon .ico { width: 23px; height: 23px; }
.why h3 { font-size: 1.08rem; }
.why p { color: var(--muted); font-size: .95rem; }

/* ============================ STREFA NA ZDJECIA ============================ */
.gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.1rem; }
.photoslot {
  position: relative; aspect-ratio: 4 / 5; border-radius: var(--radius);
  background:
    repeating-linear-gradient(135deg, var(--surface-2) 0 14px, #EAE7E0 14px 28px);
  border: 1.5px dashed var(--line-2);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 1.4rem; color: var(--muted); gap: .7rem;
}
.photoslot__ic { width: 54px; height: 54px; border-radius: 14px; background: var(--surface);
  display: grid; place-items: center; box-shadow: var(--shadow-1); color: var(--steel-600); }
.photoslot__ic .ico { width: 28px; height: 28px; }
.photoslot b { color: var(--steel); font-weight: 700; font-size: 1rem; }
.photoslot span { font-size: .88rem; max-width: 26ch; }
.photoslot__tag {
  position: absolute; left: .8rem; top: .8rem; font-size: .72rem; font-weight: 700;
  letter-spacing: .08em; text-transform: uppercase; color: var(--flame-700);
  background: var(--flame-100); padding: .25rem .6rem; border-radius: 999px;
}
.gallery-note { margin-top: 1.2rem; font-size: .95rem; color: var(--muted); display: flex; gap: .55rem; align-items: flex-start; }
.gallery-note .ico { color: var(--flame); margin-top: .2rem; }

/* ============================ PROCES ============================ */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; counter-reset: step; }
.step { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.5rem 1.3rem; box-shadow: var(--shadow-1); }
.step__n { font-family: var(--font-display); font-size: 1.6rem; color: var(--flame); line-height: 1; }
.step h3 { margin: .6rem 0 .4rem; font-size: 1.06rem; }
.step p { color: var(--muted); font-size: .93rem; }

/* ============================ KONTAKT ============================ */
.contact-grid { display: grid; grid-template-columns: .95fr 1.05fr; gap: clamp(1.4rem, 3vw, 2.6rem); align-items: start; }
.contact-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow-1); padding: 1.7rem; }
.contact-list { display: grid; gap: 1.1rem; margin-top: 1.2rem; }
.contact-row { display: flex; gap: .9rem; align-items: flex-start; }
.contact-row .ic { width: 42px; height: 42px; flex: none; border-radius: 10px; display: grid; place-items: center;
  background: var(--flame-100); color: var(--flame-700); }
.contact-row .ic .ico { width: 22px; height: 22px; }
.contact-row .k { font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
.contact-row .v { font-size: 1.12rem; font-weight: 700; color: var(--steel); }
.contact-row .v:hover { color: var(--flame-700); }
.contact-row small { color: var(--muted); font-weight: 500; font-size: .9rem; }

.map-frame { margin-top: 1.3rem; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
.map-frame iframe { width: 100%; height: 260px; border: 0; display: block; filter: saturate(.9); }

/* form */
.form { display: grid; gap: 1rem; }
.form__row { display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; }
.field { display: grid; gap: .4rem; }
.field label { font-weight: 700; font-size: .9rem; color: var(--steel); }
.field label .req { color: var(--flame); }
.field input, .field textarea {
  font-family: inherit; font-size: 1rem; color: var(--ink);
  background: var(--bg); border: 1.5px solid var(--line-2); border-radius: var(--radius-sm);
  padding: .8rem .9rem; transition: border-color .15s, box-shadow .15s;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--flame); box-shadow: 0 0 0 3px var(--flame-100); }
.field textarea { resize: vertical; min-height: 120px; }
.field .err { color: var(--flame-700); font-size: .85rem; font-weight: 600; display: none; }
.field.invalid input, .field.invalid textarea { border-color: var(--flame-700); }
.field.invalid .err { display: block; }
.form__hint { font-size: .85rem; color: var(--muted); display: flex; gap: .5rem; align-items: flex-start; }
.form__hint .ico { color: var(--ok); margin-top: .15rem; width: 1.05em; height: 1.05em; }
.form__status { font-weight: 700; color: var(--ok); display: none; align-items: center; gap: .5rem; }
.form__status.show { display: flex; }
.form__status .ico { color: var(--ok); }

/* ============================ FOOTER ============================ */
.footer { background: var(--steel); color: #C6D3D5; padding: clamp(2.6rem, 5vw, 3.6rem) 0 1.6rem; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2rem; }
.footer .brand__name, .footer .brand__sub { color: #fff; }
.footer__brand p { margin-top: 1rem; max-width: 38ch; font-size: .95rem; color: #A9BCBF; }
.footer h4 { color: #fff; font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; margin-bottom: .9rem; }
.footer ul { display: grid; gap: .55rem; }
.footer a { color: #C6D3D5; font-size: .96rem; }
.footer a:hover { color: #F4B58C; }
.footer__row { display: flex; gap: .6rem; align-items: flex-start; font-size: .96rem; }
.footer__row .ico { color: #F4B58C; margin-top: .2rem; width: 1.05em; height: 1.05em; }
.footer__bottom { margin-top: 2.4rem; padding-top: 1.3rem; border-top: 1px solid rgba(255,255,255,.12);
  display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; align-items: center; justify-content: space-between;
  font-size: .87rem; color: #93A8AB; }
.footer__bottom a { color: #93A8AB; text-decoration: underline; text-underline-offset: 3px; }

/* ============================ MOBILE NAV ============================ */
@media (max-width: 980px) {
  .nav { position: fixed; inset: var(--header-h) 0 auto 0; background: var(--bg);
    border-bottom: 1px solid var(--line); transform: translateY(-12px); opacity: 0; pointer-events: none;
    transition: transform .2s ease, opacity .2s ease; box-shadow: var(--shadow-2); margin: 0; }
  .nav.open { transform: translateY(0); opacity: 1; pointer-events: auto; }
  .nav__list { flex-direction: column; align-items: stretch; gap: .15rem; padding: 1rem clamp(1.1rem,4vw,2.2rem) 1.3rem; }
  .nav__list a { padding: .85rem .6rem; font-size: 1.05rem; border-bottom: 1px solid var(--line); }
  .nav__list a:hover { background: transparent; }
  .header__cta .btn { display: none; }
  .burger { display: inline-flex; margin-left: auto; }
  .header__cta { margin-left: 0; }
  .header__inner { gap: .8rem; }
}

/* ============================ RESPONSIVE ============================ */
@media (max-width: 900px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__card { max-width: 460px; }
  .svc-grid { grid-template-columns: repeat(2, 1fr); }
  .why-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .contact-grid { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .footer__brand { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  body { font-size: 1rem; }
  .svc-grid, .why-grid, .gallery-grid, .steps { grid-template-columns: 1fr; }
  .form__row { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .hero__actions .btn { flex: 1 1 auto; justify-content: center; }
  .brand__sub { display: none; }
}

/* ============================ REVEAL (enhancement + safety net) ============================ */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1 !important; transform: none !important; transition: none; }
  .btn, .svc, .photoslot { transition: none; }
}
