/* CloudHub (Dekatron Sp. z o.o.) — arkusz stylów
   Kolory marki Dekatron: granat #0D4162, niebieski #2E85C4. Krój Archivo (nagłówki szersze).
   Główny motyw: ekrany portalu na granicy jasnego tła i granatu. */

:root {
  --ink: #15222e;
  --ink-2: #4b5966;
  --ink-3: #7b8792;
  --navy: #0d4162;
  --navy-dark: #092f47;
  --blue: #2e85c4;
  --blue-dark: #236ba0;
  --paper: #f3f2ee;
  --line: #dadddf;
  --line-dark: rgba(255, 255, 255, .16);
  --white: #fff;
  --wrap: 1240px;
  --gutter: 32px;
  --head: "Archivo", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0; font-family: var(--head); font-size: 17px; line-height: 1.6;
  color: var(--ink); background: var(--white); -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: var(--blue-dark); text-decoration: none; }
a:hover { color: var(--navy); }
p { margin: 0 0 1em; }
ul, ol, dl, dd { margin: 0; padding: 0; }
address { font-style: normal; }

h1, h2, h3, h4 {
  margin: 0; font-family: var(--head); font-stretch: 112%; font-weight: 600;
  line-height: 1.12; letter-spacing: -0.012em; color: var(--ink);
}
h1 { font-size: clamp(38px, 6.4vw, 80px); line-height: 1.02; letter-spacing: -0.024em; }
h2 { font-size: clamp(28px, 3.4vw, 42px); }
h3 { font-size: 20px; }

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

/* ---------- przyciski ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px; padding: 14px 24px;
  font: 600 16px/1 var(--head); border: 1px solid var(--navy); border-radius: 2px;
  background: var(--navy); color: var(--white); transition: background .15s, border-color .15s;
}
.btn:hover { background: var(--navy-dark); border-color: var(--navy-dark); color: var(--white); }
.arrow-link { font-weight: 600; color: var(--ink); border-bottom: 1px solid currentColor; padding-bottom: 2px; }
.arrow-link::after { content: " →"; }
.arrow-link:hover { color: var(--blue-dark); }

/* ---------- nagłówek ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .97); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; gap: 40px; height: 76px; }
.brand { display: flex; align-items: center; gap: 12px; flex-shrink: 0; color: var(--ink); }
.brand .mark { height: 34px; width: auto; }
.brand .prod { font-stretch: 125%; font-weight: 600; font-size: 21px; letter-spacing: -0.01em; color: var(--navy); }
.nav { display: flex; gap: 26px; margin-left: auto; list-style: none; }
.nav a { color: var(--ink); font-size: 15px; font-weight: 500; padding: 6px 0; border-bottom: 2px solid transparent; }
.nav a:hover { color: var(--blue-dark); border-bottom-color: var(--blue); }
.login { font-size: 15px; font-weight: 600; color: var(--navy); padding: 10px 16px; border: 1px solid var(--navy); border-radius: 2px; white-space: nowrap; }
.login:hover { background: var(--navy); color: var(--white); }
.nav-login { display: none; }
.zoom { display: block; cursor: zoom-in; }
.nav-toggle {
  display: none; margin-left: auto; background: none; border: 1px solid var(--line); border-radius: 2px;
  font: 600 15px var(--head); color: var(--ink); padding: 9px 14px; cursor: pointer;
}

/* ---------- sekcje ---------- */
.section { padding: 104px 0; }
.section.paper { background: var(--paper); }
.split { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 32px 64px; align-items: start; }
.split > .side h2 { max-width: 12ch; }
.side .note { color: var(--ink-2); font-size: 16px; margin-top: 18px; max-width: 30ch; }
.lead { font-size: 20px; line-height: 1.55; color: var(--ink-2); }

/* ---------- hero: ekran portalu na granicy bieli i granatu ---------- */
.hero { padding: 84px 0 0; }
.hero h1 { max-width: 16ch; }
.hero-row { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 32px 64px; margin-top: 40px; align-items: end; }
.hero-row .lead { margin: 0; max-width: 50ch; }
.hero-actions { display: flex; gap: 28px; align-items: center; flex-wrap: wrap; justify-self: end; }
.hero-screen { margin: 64px 0 0; padding-bottom: 56px; background: linear-gradient(var(--white) 0, var(--white) 46%, var(--navy) 46%); }
.hero-screen img { border: 1px solid #c9ced3; border-radius: 6px; width: 100%; }
.hero-screen figcaption { color: #b9cbd9; }

/* ---------- ekrany portalu ---------- */
.screen { margin: 64px 0 0; }
.screen img { width: 100%; border: 1px solid var(--line); border-radius: 6px; background: var(--white); }
.screen figcaption { margin-top: 12px; font-size: 14px; color: var(--ink-3); }

/* ---------- jak działa ---------- */
.flow { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 32px; }
.flow > li { border-top: 2px solid var(--navy); padding-top: 18px; position: relative; }
.flow > li + li::before {
  content: "→"; position: absolute; left: -26px; top: 12px; color: var(--blue); font-size: 18px;
}
.flow .n { display: block; font-size: 14px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.flow h3 { font-size: 22px; margin: 4px 0 14px; }
.flow ul { list-style: none; }
.flow ul li { padding: 9px 0; border-top: 1px solid var(--line); font-size: 15px; line-height: 1.45; color: var(--ink-2); }

/* ---------- co odczytujemy ---------- */
.measure { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 0 40px; }
.measure li { padding: 22px 0; border-top: 1px solid var(--line); }
.measure h3 { font-size: 19px; margin-bottom: 8px; }
.measure p { margin: 0; color: var(--ink-2); font-size: 15.5px; line-height: 1.55; }
.protocols { margin: 8px 0 0; padding: 18px 0; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--line); font-size: 16px; }
.protocols span { color: var(--ink-3); margin-right: 8px; }
.foot-note { margin-top: 14px; font-size: 14px; color: var(--ink-3); }

/* ---------- wiersze tytuł + opis ---------- */
.rows { margin-top: 28px; border-bottom: 1px solid var(--line); }
.rows > div { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 5fr); gap: 8px 32px; padding: 18px 0; border-top: 1px solid var(--line); }
.rows dt { font-stretch: 112%; font-weight: 600; font-size: 17px; line-height: 1.35; }
.rows dd { color: var(--ink-2); font-size: 16px; line-height: 1.55; }
.split > .rows { margin-top: 0; }
.rows.two { display: grid; grid-template-columns: 1fr 1fr; gap: 0 40px; border-bottom: 0; }
.rows.two > div { grid-template-columns: 1fr; }

/* ---------- alarmy ---------- */
.sms { margin-top: 32px; padding: 18px 22px; background: var(--white); border-left: 3px solid var(--blue); }
.sms span { display: block; font-size: 14px; color: var(--ink-3); margin-bottom: 4px; }
.sms p { margin: 0; font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 15px; line-height: 1.5; color: var(--ink); overflow-wrap: anywhere; }
.reports-split { margin-top: 64px; }
.reports-split h3 { font-size: 24px; }
.reports { width: 100%; border-collapse: collapse; font-size: 16px; }
.reports th, .reports td { padding: 15px 0; border-top: 1px solid var(--line); text-align: left; vertical-align: baseline; }
.reports tr:last-child th, .reports tr:last-child td { border-bottom: 1px solid var(--line); }
.reports th { font-weight: 600; padding-right: 24px; white-space: nowrap; }
.reports td { color: var(--ink-2); }
.reports .fmt { text-align: right; font-weight: 600; color: var(--navy); font-size: 14px; padding-left: 16px; letter-spacing: .04em; }

/* ---------- zastosowania / kroki ---------- */
.uses, .steps { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 0 40px; }
.uses li, .steps li { padding: 20px 0; border-top: 1px solid var(--line); }
.uses strong, .steps strong { display: block; font-stretch: 112%; font-weight: 600; font-size: 19px; margin-bottom: 4px; }
.uses span, .steps span { display: block; color: var(--ink-2); font-size: 16px; line-height: 1.5; }
.steps { counter-reset: s; }
.steps li { counter-increment: s; }
.steps strong::before { content: counter(s, decimal-leading-zero) "  "; color: var(--blue); white-space: pre; }

/* ---------- granatowe pasmo ze zdjęciem ---------- */
.photo-band { background: var(--navy); color: #c7d6e2; }
.photo-band h2 { color: var(--white); margin-bottom: 24px; max-width: 16ch; }
.photo-band p { font-size: 18px; line-height: 1.6; max-width: 54ch; }
.photo-band a { color: var(--white); border-bottom: 1px solid rgba(255, 255, 255, .5); }
.band-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 40px 72px; align-items: center; }
.band-photo { margin: 0; }
.band-photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }

/* ---------- FAQ ---------- */
.faq { border-bottom: 1px solid var(--line); }
.faq details { border-top: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 20px 40px 20px 0; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 16px; font-size: 24px; color: var(--ink-3); }
.faq details[open] summary::after { content: "–"; }
.faq summary h3 { font-size: 19px; display: inline; }
.faq summary:hover h3 { color: var(--blue-dark); }
.faq details p { margin: 0 0 22px; color: var(--ink-2); max-width: 64ch; }

/* ---------- kontakt ---------- */
.contact-band { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: 40px 72px; align-items: end; }
.contact-band h2 { max-width: 16ch; margin-bottom: 18px; }
.contact-band p { color: var(--ink-2); margin: 0; max-width: 46ch; }
.contact-lines { list-style: none; }
.contact-lines li { display: flex; justify-content: space-between; gap: 16px; padding: 16px 0; border-top: 1px solid var(--line); align-items: baseline; flex-wrap: wrap; }
.contact-lines li:last-child { border-bottom: 1px solid var(--line); }
.contact-lines span { color: var(--ink-3); font-size: 15px; }
.contact-lines a { font-stretch: 112%; font-size: 22px; font-weight: 600; color: var(--ink); overflow-wrap: anywhere; }
.contact-lines a:hover { color: var(--blue-dark); }

/* ---------- stopka ---------- */
.site-footer { background: var(--navy-dark); color: #a9bccb; font-size: 15px; padding: 72px 0 32px; }
.site-footer a { color: #d5e1ea; }
.site-footer a:hover { color: var(--white); }
.foot-grid { display: grid; grid-template-columns: minmax(0, 6fr) repeat(2, minmax(0, 3fr)); gap: 40px; }
.dk { display: flex; align-items: center; gap: 12px; margin-bottom: 22px; }
.dk .mark { height: 34px; width: auto; }
.dk .word { height: 14px; width: auto; }
.foot-brand p { max-width: 46ch; }
.site-footer h4 { color: var(--white); font-size: 15px; font-stretch: 100%; font-weight: 600; letter-spacing: 0; margin-bottom: 14px; }
.site-footer ul { list-style: none; }
.site-footer li { margin-bottom: 8px; }
.foot-bottom { margin-top: 56px; padding-top: 22px; border-top: 1px solid var(--line-dark); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 14px; color: #7f98ab; }

/* ---------- responsywność ---------- */
@media (max-width: 1120px) {
  .nav { gap: 18px; }
  .nav li:nth-child(n+5) { display: none; }
}

@media (max-width: 900px) {
  :root { --gutter: 24px; }
  .section { padding: 72px 0; }
  .nav-toggle { display: block; }
  .login { margin-left: auto; }
  .nav-toggle { margin-left: 0; }
  .nav {
    display: none; position: absolute; top: 76px; left: 0; right: 0; flex-direction: column; gap: 0;
    background: var(--white); border-bottom: 1px solid var(--line); padding: 8px var(--gutter) 16px;
  }
  .nav li:nth-child(n+5) { display: list-item; }
  .nav li.nav-login { display: none; }
  .nav.open { display: flex; }
  .nav a { display: block; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .split, .hero-row, .contact-band, .band-grid { grid-template-columns: 1fr; }
  .split > .side h2 { max-width: none; }
  .side .note { max-width: 56ch; }
  .hero-actions { justify-self: start; }
  .flow { grid-template-columns: 1fr; gap: 32px; }
  .flow > li + li::before { content: none; }
  .band-photo img { aspect-ratio: 16 / 9; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .foot-brand { grid-column: 1 / -1; }
  .screen, .reports-split { margin-top: 48px; }
}

@media (max-width: 640px) {
  :root { --gutter: 16px; }
  body { font-size: 16px; }
  .hero { padding-top: 48px; }
  .lead { font-size: 18px; }
  .hero-screen { margin-top: 40px; padding-bottom: 40px; }
  .brand .mark { height: 28px; }
  .brand .prod { font-size: 18px; }
  .login { padding: 8px 10px; font-size: 14px; }
  .measure, .uses, .steps, .rows.two { grid-template-columns: 1fr; }
  .rows > div { grid-template-columns: 1fr; gap: 4px; }
  .reports th { white-space: normal; display: block; padding-bottom: 2px; border-top: 1px solid var(--line); }
  .reports tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; }
  .reports th { grid-column: 1 / -1; }
  .reports td { border-top: 0; padding-top: 0; }
  .reports tr:last-child th { border-bottom: 0; }
  .contact-lines a { font-size: 19px; }
  .foot-grid { grid-template-columns: 1fr; }
}

@media (max-width: 400px) {
  .login { display: none; }
  .nav li.nav-login { display: list-item; }
  .nav-toggle { margin-left: auto; }
}
