/* ==========================================================================
   Platforma inspekcji termowizyjnych Fire Risk – ir.fire-risk.pl
   Styl spójny z www.fire-risk.pl (Archivo 500 + Inter, pomarańcz #F05626).
   ========================================================================== */

/* --- Fonty hostowane lokalnie (OFL) -------------------------------------- */
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/archivo-latin-ext-wght-normal.woff2") format("woff2-variations");
  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-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/archivo-latin-wght-normal.woff2") format("woff2-variations");
  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;
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/inter-latin-ext-wght-normal.woff2") format("woff2-variations");
  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-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/inter-latin-wght-normal.woff2") format("woff2-variations");
  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;
}

/* --- Tokeny --------------------------------------------------------------- */
:root {
  --orange: #F05626;          /* kolor podstawowy marki: grafiki, duże napisy, kropki */
  --orange-btn: #CF4517;      /* tło przycisków – biały tekst ma tu kontrast 4,6:1 (WCAG AA) */
  --orange-btn-hover: #B93E14;
  --orange-ink: #B93E14;      /* mały pomarańczowy tekst na jasnym tle */
  --orange-on-dark: #F4764E;  /* mały pomarańczowy tekst na ciemnym tle */
  --ink: #28272A;             /* czerń marki */
  --light: #F1EFEE;           /* jasny ton marki */
  --white: #FFFFFF;
  --muted: #5A585D;
  --on-dark-muted: #D9D6D4;
  --rule: #C9C6C4;
  --rule-soft: #E3E0DE;
  --rule-dark: #4A484D;
  --navy: #120D32;            /* tło ilustracji termowizyjnej */
  --font-head: "Archivo", Arial, sans-serif;
  --font-body: "Inter", Arial, sans-serif;
  --radius-card: 12px;
  --radius-btn: 4px;
}

/* --- Podstawy ------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 25px;
  overflow-wrap: break-word;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3 {
  margin: 0;
  font-family: var(--font-head);
  font-weight: 500;
  letter-spacing: -0.2px;
  text-wrap: balance;
}
h1 { font-size: clamp(36px, 5vw, 56px); line-height: 1.1; }
h2 { font-size: clamp(30px, 3.6vw, 42px); line-height: 1.1; }
h3 { font-size: 22px; line-height: 26px; }
p { margin: 0; text-wrap: pretty; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; }
[id] { scroll-margin-top: 96px; }

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--white); color: var(--ink); padding: 12px 16px;
}
.skip-link:focus { left: 16px; top: 16px; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

.container { width: 100%; max-width: 1368px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.section { padding: 96px 0; }
.section--light { background: var(--light); }
.section--dark { position: relative; overflow: hidden; background: var(--ink); color: var(--light); }

/* --- Przyciski i etykiety ------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 50px; padding: 10px 20px;
  border: 0; border-radius: var(--radius-btn);
  background: var(--orange-btn); color: var(--white);
  font-family: var(--font-body); font-size: 16px; font-weight: 600; line-height: 1.2;
  text-decoration: none; cursor: pointer;
  transition: background-color .15s ease;
}
.btn:hover { background: var(--orange-btn-hover); }
.btn svg { flex: none; }
.btn--outline { background: transparent; border: 1.5px solid currentColor; color: var(--light); }
.btn--outline:hover { background: rgba(255, 255, 255, .12); }

.badge {
  display: inline-flex; align-items: center; gap: 10px;
  border: 1.33px solid currentColor; border-radius: 50px;
  padding: 5px 20px; font-size: 15px;
}
.badge::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--orange); }

.section-head { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; margin-bottom: 48px; }
.section-head--center { align-items: center; text-align: center; }
.section-head p { max-width: 680px; }

/* --- Pasek górny i nagłówek ---------------------------------------------- */
.topbar { background: var(--ink); color: var(--light); font-size: 14px; }
.topbar__inner { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0 28px; }
.topbar a { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; text-decoration: none; }
.topbar a:hover { text-decoration: underline; }

.header { position: sticky; top: 0; z-index: 50; background: var(--white); border-bottom: 1px solid var(--rule-soft); }
.header__inner { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 16px 32px; padding-top: 14px; padding-bottom: 14px; }
.header__logo { display: inline-flex; align-items: center; min-height: 44px; }
.header__logo img { height: 40px; width: auto; }
.nav { display: flex; align-items: center; gap: 4px 28px; }
.nav__link { display: inline-flex; align-items: center; min-height: 44px; color: var(--ink); text-decoration: none; }
.nav__link:hover { color: var(--orange-ink); }
.nav__link[aria-current="page"] { font-weight: 600; box-shadow: inset 0 -2px 0 var(--orange); }
.nav-toggle {
  display: none; align-items: center; justify-content: center;
  width: 48px; height: 48px; padding: 0;
  background: transparent; border: 1.5px solid var(--ink); border-radius: var(--radius-btn);
  color: var(--ink); cursor: pointer;
}

@media (max-width: 1140px) {
  .nav-toggle { display: inline-flex; }
  .nav {
    display: none;
    position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    padding: 8px 24px 20px;
    background: var(--white); border-bottom: 1px solid var(--rule-soft);
    box-shadow: 0 12px 24px rgba(40, 39, 42, .08);
  }
  .nav.is-open { display: flex; }
  .nav__link { min-height: 48px; border-bottom: 1px solid var(--rule-soft); }
  .nav .btn { margin-top: 16px; align-self: flex-start; }
}

/* Dłuższe nazwy w menu (DE, IT, FR, ES): menu mobilne już poniżej 1280 px */
.nav__link, .nav .btn { white-space: nowrap; }
@media (min-width: 1141px) and (max-width: 1280px) {
  html:is([lang="de"], [lang="it"], [lang="fr"], [lang="es"]) .nav-toggle { display: inline-flex; }
  html:is([lang="de"], [lang="it"], [lang="fr"], [lang="es"]) .nav {
    display: none;
    position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    padding: 8px 24px 20px;
    background: var(--white); border-bottom: 1px solid var(--rule-soft);
    box-shadow: 0 12px 24px rgba(40, 39, 42, .08);
  }
  html:is([lang="de"], [lang="it"], [lang="fr"], [lang="es"]) .nav.is-open { display: flex; }
  html:is([lang="de"], [lang="it"], [lang="fr"], [lang="es"]) .nav__link { min-height: 48px; border-bottom: 1px solid var(--rule-soft); }
  html:is([lang="de"], [lang="it"], [lang="fr"], [lang="es"]) .nav .btn { margin-top: 16px; align-self: flex-start; }
}

/* --- Hero ----------------------------------------------------------------- */
.hero { position: relative; overflow: hidden; background: var(--navy); color: var(--light); }
.hero__bg { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; object-position: right center; }
.hero__shade {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, #120D32 0%, rgba(18, 13, 50, .94) 38%, rgba(18, 13, 50, .45) 68%, rgba(18, 13, 50, .12) 100%);
}
.hero__inner {
  position: relative; min-height: 620px; padding-top: 96px; padding-bottom: 96px;
  display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 24px;
}
.hero h1 { max-width: 800px; }
.hero p { max-width: 640px; font-size: 17px; line-height: 27px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; }

/* --- Moduły ---------------------------------------------------------------- */
.modules { display: flex; flex-wrap: wrap; gap: 20px; }
.card {
  flex: 1 1 300px; min-width: 0;
  background: var(--white); border-radius: var(--radius-card); padding: 28px;
  display: flex; flex-direction: column; gap: 14px;
}
.card--wide { flex-basis: 520px; }
.card__icon { width: 48px; height: 48px; border-radius: 10px; background: var(--light); display: flex; align-items: center; justify-content: center; }
.card ul { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; font-size: 15px; line-height: 22px; }
.card__norms { margin-top: auto; border-top: 1px solid var(--rule-soft); padding-top: 14px; font-size: 13px; line-height: 20px; }
.card__norms span { color: var(--muted); }
.note { margin: 32px auto 0; max-width: 880px; text-align: center; font-size: 15px; line-height: 24px; color: var(--muted); }

/* --- Kroki i zrzuty --------------------------------------------------------- */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 32px; }
.step { border-top: 2px solid var(--ink); padding-top: 20px; display: flex; flex-direction: column; gap: 10px; }
.step__num { font-family: var(--font-head); font-weight: 500; font-size: 56px; line-height: 1; color: var(--orange); }
.shot { margin: 56px 0 0; }
.shot__frame { overflow: hidden; border: 1px solid var(--rule); border-radius: var(--radius-card); background: var(--white); }
.shot__frame img { width: 100%; }
.shot figcaption { margin-top: 12px; font-size: 14px; line-height: 22px; color: var(--muted); }

/* --- Raporty i normy -------------------------------------------------------- */
.split { display: flex; flex-wrap: wrap; gap: 48px 64px; align-items: flex-start; }
.split__main { flex: 1 1 520px; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 20px; }
.checklist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.checklist li { display: flex; gap: 12px; }
.checklist li::before {
  content: ""; flex: none; width: 20px; height: 25px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%23B93E14' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 10.5l4 4 8-9'/%3E%3C/svg%3E") center / 20px no-repeat;
}
.report { flex: 1 1 380px; min-width: 0; margin: 0; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.report__frame { width: 100%; max-width: 420px; background: var(--white); border-radius: var(--radius-card); padding: 16px; }
.report__frame img { width: 100%; }
.report figcaption { max-width: 420px; font-size: 14px; line-height: 22px; color: var(--muted); }
.facts {
  margin-top: 48px; background: var(--white); border-radius: var(--radius-card); padding: 32px;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); gap: 28px 32px;
}
.fact { border-left: 3px solid var(--orange); padding-left: 18px; display: flex; flex-direction: column; gap: 6px; }
.fact h3, .feature h3, .row h3 { font-size: 20px; line-height: 24px; }
.fact p, .feature p { font-size: 15px; line-height: 22px; }

/* --- Portal klienta ---------------------------------------------------------- */
.features { margin-top: 40px; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); gap: 28px 32px; }
.feature { border-top: 2px solid var(--ink); padding-top: 16px; display: flex; flex-direction: column; gap: 6px; }

/* --- Usługa ITC --------------------------------------------------------------- */
.watermark { position: absolute; right: -120px; bottom: -90px; width: 760px; max-width: none; pointer-events: none; }
.section--dark .container { position: relative; }
.numlist { flex: 1 1 420px; min-width: 0; list-style: none; margin: 0; padding: 0; counter-reset: krok; }
.numlist li { counter-increment: krok; border-top: 1px solid var(--rule-dark); padding: 20px 0; display: flex; gap: 20px; align-items: baseline; }
.numlist li:last-child { border-bottom: 1px solid var(--rule-dark); }
.numlist li::before { content: counter(krok); flex: none; width: 28px; font-family: var(--font-head); font-weight: 500; font-size: 28px; line-height: 1; color: var(--orange); }

/* --- Kontakt ------------------------------------------------------------------ */
.contact { position: relative; overflow: hidden; background: var(--navy); color: var(--light); padding: 96px 0; }
.contact__bg { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; }
.contact__shade { position: absolute; inset: 0; background: rgba(18, 13, 50, .88); }
.contact .container { position: relative; }
.contact .split__main { flex-basis: 480px; }
.tiles { width: 100%; margin-top: 8px; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 16px; }
.tile { background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .2); border-radius: 8px; padding: 18px 20px; display: flex; flex-direction: column; gap: 4px; }
.tile__label { font-size: 12px; line-height: 18px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--orange-on-dark); }
.tile a { text-decoration: none; }
.tile a:hover { text-decoration: underline; }
.form { flex: 1 1 480px; min-width: 0; background: var(--ink); border-radius: var(--radius-card); padding: 32px; display: flex; flex-direction: column; gap: 16px; }
.form h3 { font-size: 24px; line-height: 28px; margin-bottom: 4px; }
.form__row { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); gap: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 14px; line-height: 20px; }
.field input, .field textarea {
  width: 100%; height: 48px; padding: 0 14px;
  border: 1px solid var(--rule); border-radius: 6px;
  background: var(--white); color: var(--ink);
  font-family: var(--font-body); font-size: 16px; line-height: 24px;
}
.field textarea { height: auto; min-height: 120px; padding: 12px 14px; resize: vertical; }
.consent { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; line-height: 22px; }
.consent input { flex: none; width: 20px; height: 20px; margin: 2px 0 0; }
.form .btn { align-self: flex-start; }
.form__status { font-size: 14px; line-height: 22px; }
.form__status:empty { display: none; }
.form__status--ok { color: #8FD9A8; font-weight: 600; }
.form__status--error { color: var(--orange-on-dark); font-weight: 600; }
.field__error { margin: 0; font-size: 14px; line-height: 20px; color: var(--orange-on-dark); }
.consent + .field__error { margin-top: -10px; padding-left: 32px; font-size: 14px; line-height: 20px; color: var(--orange-on-dark); }
.field [aria-invalid="true"] { border: 2px solid var(--orange-on-dark); }
.consent input[aria-invalid="true"] { outline: 2px solid var(--orange-on-dark); outline-offset: 2px; }
.form .btn:disabled { opacity: .6; cursor: progress; }
.hp { position: absolute; left: -9999px; }

/* --- Stopka ------------------------------------------------------------------- */
.footer { background: var(--ink); color: var(--light); padding: 64px 0 28px; }
.footer__cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 40px 48px; }
.footer__brand img { height: 36px; width: auto; }
.footer__brand p { margin-top: 16px; font-size: 14px; line-height: 22px; color: var(--on-dark-muted); }
.footer h2 { margin-bottom: 4px; font-family: var(--font-body); font-size: 16px; line-height: 25px; font-weight: 600; letter-spacing: 0; color: var(--orange-on-dark); }
.footer ul { list-style: none; margin: 0; padding: 0; }
.footer li a { display: inline-flex; align-items: center; min-height: 36px; text-decoration: none; }
.footer li a:hover { text-decoration: underline; }
.footer__bottom {
  margin-top: 40px; border-top: 1px solid var(--rule-dark); padding-top: 20px;
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px;
  font-size: 14px; line-height: 22px; color: var(--on-dark-muted);
}

/* --- Cennik -------------------------------------------------------------------- */
.page-head { position: relative; overflow: hidden; background: var(--ink); color: var(--light); padding: 72px 0; }
.page-head .container { position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 16px; }
.page-head p { max-width: 620px; font-size: 17px; line-height: 27px; }
.page-head .watermark { bottom: -150px; }
.todo { color: var(--orange-ink); border-bottom: 1.5px dashed var(--orange-ink); }
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 20px; }
.plan { background: var(--white); border-radius: var(--radius-card); padding: 32px; display: flex; flex-direction: column; align-items: flex-start; gap: 16px; }
.plan__price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.plan__price strong { font-family: var(--font-head); font-weight: 500; font-size: 40px; line-height: 1.1; }
.plan__price > span { font-size: 14px; color: var(--muted); }
.plan .checklist { align-self: stretch; }
.plan .btn { margin-top: 8px; }
.rows { border-top: 2px solid var(--ink); }
.row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px 32px; padding: 20px 0; border-bottom: 1px solid var(--rule); }
.row__main { flex: 1 1 420px; min-width: 0; }
.row p { margin-top: 4px; font-size: 15px; line-height: 22px; color: var(--muted); }
.row__value { font-size: 18px; font-weight: 600; }
.cta { background: var(--orange); color: var(--white); padding: 72px 0; }
.cta .container { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 24px 64px; }
.cta h2 { flex: 1 1 420px; min-width: 0; }
.cta__links { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; font-size: 24px; line-height: 36px; font-weight: 600; }
.cta__links a { text-decoration: none; }
.cta__links a:hover { text-decoration: underline; }

/* --- Mniejsze ekrany ----------------------------------------------------------- */
@media (max-width: 760px) {
  .section, .contact { padding: 64px 0; }
  .section-head { margin-bottom: 32px; }
  .hero__shade { background: rgba(18, 13, 50, .84); }
  .hero__inner { min-height: 0; padding-top: 72px; padding-bottom: 72px; }
  .header__logo img { height: 34px; }
  .topbar__inner { justify-content: center; }
  .shot { margin-top: 40px; }
  .form, .facts, .plan { padding: 24px; }
  .watermark { width: 520px; right: -160px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn { transition: none; }
}

/* --- Logowanie do platformy (pv.fire-risk.pl) ---------------------------------- */
.topbar__login { font-weight: 600; }

/* --- Cennik: cztery pakiety w jednym rzędzie na szerokim ekranie ------------------ */
.plans--4 { grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr)); }
.plans--4 .plan { padding: 28px; }
.plans--4 .plan__price strong { font-size: 36px; white-space: nowrap; }

/* --- Przełącznik języków (górny pasek) ------------------------------------------- */
.lang { display: flex; align-items: center; gap: 2px; margin-right: auto; }
.topbar .lang a { min-height: 44px; min-width: 32px; justify-content: center; padding: 0 4px; gap: 0; font-size: 13px; font-weight: 600; letter-spacing: .04em; color: var(--on-dark-muted); }
.topbar .lang a:hover { color: var(--white); }
.topbar .lang a[aria-current="true"] { color: var(--white); text-decoration: underline; text-decoration-color: var(--orange); text-decoration-thickness: 2px; text-underline-offset: 5px; }
@media (max-width: 720px) {
  .lang { width: 100%; justify-content: center; margin-right: 0; }
}
