/* ---------- Fonts (self-hosted, bez Google Fonts – RODO) ---------- */
/* Boska (Fontshare, ITF Free Font License – public/fonts/Boska-LICENSE-FFL.txt) */
@font-face {
  font-family: "Boska";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/Boska-Regular.woff2") format("woff2");
}
@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;
}
@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;
}

/* ---------- Tokens ---------- */
:root {
  /* paleta z Framera (wartości z makiety) */
  --ziele-lesna: #30473b;
  --eukaliptus: #718374;
  --szalwia: #e4e9e0;
  --kamien: #e4e1da;
  --ciepla-biel: #f7f5f0;

  --bg: var(--ciepla-biel);
  --bg-alt: var(--szalwia);
  --surface: var(--kamien);
  --ink: #2c3630;
  --ink-soft: #4a544d;
  --accent: var(--ziele-lesna);
  --accent-hover: #253a2f;
  --line: #d9dad3;
  --white: #fbfbf8;
  --radius-lg: 22px;
  --radius-md: 12px;
  --container: 1200px;
  --gutter: clamp(20px, 5vw, 72px);
  --serif: "Boska", Georgia, "Times New Roman", serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
picture { display: block; }
a { color: inherit; }
p { margin: 0 0 1.1em; }
address { font-style: normal; }

.container {
  width: 100%;
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.visually-hidden, .hp {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}
.skip-link {
  position: absolute; left: 12px; top: -60px;
  background: var(--accent); color: var(--white);
  padding: 8px 14px; border-radius: 8px; z-index: 100;
}
.skip-link:focus { top: 12px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* ---------- Typography ---------- */
.display {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(44px, 6.2vw, 76px);   /* Nagłówek redakcyjny 76/1.0 */
  line-height: 1;
  letter-spacing: -0.02em;
  margin: 0 0 28px;
  color: var(--accent);
}
.display-sm { font-size: clamp(38px, 4vw, 48px); line-height: 1.1; margin-bottom: 24px; }   /* Tytuł sekcji 48/1.1 */
.lead {
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink-soft);
  max-width: 28em;
  margin-bottom: 32px;
}

.label {   /* Etykieta 12/1.2 */
  font: 600 12px/1.2 var(--sans);
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--eukaliptus);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--accent); color: var(--white);
  font: 600 15px/1 var(--sans);
  text-decoration: none;
  border: 0; border-radius: 999px;
  padding: 17px 30px;
  cursor: pointer;
  transition: background-color .2s ease, transform .2s ease;
}
.btn:hover { background: var(--accent-hover); }
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: .6; cursor: progress; }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 96px;
}
.brand { text-decoration: none; display: flex; flex-direction: column; gap: 4px; }
.brand-name { font-family: var(--serif); font-size: 32px; line-height: 1; color: var(--accent); }
.brand-sub { font-size: 14px; color: var(--ink-soft); }
.site-nav { display: flex; gap: 32px; }
.site-nav a { text-decoration: none; font-size: 15px; font-weight: 500; }
.site-nav a:hover { text-decoration: underline; text-underline-offset: 4px; }
.nav-toggle {
  display: none;
  width: 44px; height: 44px; padding: 10px;
  background: none; border: 0; cursor: pointer;
  flex-direction: column; justify-content: center; gap: 6px;
}
.nav-toggle span { display: block; height: 2px; background: var(--ink); border-radius: 2px; transition: transform .25s, opacity .25s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  min-height: min(78vh, 760px);
  display: flex; align-items: center;
  padding: 96px 0;
}
.hero .display { max-width: 9.5em; }

/* ---------- About ---------- */
.about { background: var(--bg-alt); padding: clamp(64px, 9vw, 112px) 0; }
.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: clamp(32px, 6vw, 72px);
  align-items: start;
}
.portrait {
  width: 100%;
  aspect-ratio: 720 / 780;
  object-fit: cover;
  object-position: 50% 15%;
  border-radius: var(--radius-lg);
  background: #d6dad1;
}
.cert { margin: 40px auto 0; max-width: 420px; text-align: center; }
.cert-title {
  font-family: var(--serif);
  font-size: clamp(24px, 2.4vw, 30px);
  color: var(--accent);
  margin-bottom: 20px;
}
.cert a { display: block; cursor: zoom-in; }
.cert img { border-radius: var(--radius-md); box-shadow: 0 1px 0 rgba(0,0,0,.04), 0 10px 30px -18px rgba(0,0,0,.35); }
.about-text { font-size: 17px; line-height: 1.6; color: var(--ink-soft); }

/* ---------- Contact ---------- */
.contact { padding: clamp(64px, 9vw, 112px) 0 clamp(64px, 8vw, 96px); }
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(32px, 6vw, 64px) clamp(32px, 6vw, 72px);
  align-items: start;
}
.contact-info address { color: var(--ink-soft); font-size: 17px; }
.contact-info address p { margin-bottom: 1.4em; }
.contact-info a { text-decoration: none; }
.contact-info a:hover { text-decoration: underline; }

.contact-form {
  background: var(--bg-alt);
  border-radius: var(--radius-lg);
  padding: clamp(24px, 3vw, 32px);
}
.field { margin-bottom: 18px; }
.field label { display: block; font-size: 13px; font-weight: 500; margin-bottom: 8px; }
.field input, .field textarea {
  width: 100%;
  font: 15px/1.5 var(--sans);
  color: var(--ink);
  background: var(--white);
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 12px 14px;
  transition: border-color .2s, box-shadow .2s;
}
.field textarea { resize: vertical; min-height: 140px; }
.field input:focus, .field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(48, 71, 59, .12);
}
.field input[aria-invalid="true"], .field textarea[aria-invalid="true"] { border-color: #a5432f; }
.form-note { font-size: 12px; color: var(--ink-soft); margin: 4px 0 16px; }
.cf-turnstile-slot:not(:empty) { margin-bottom: 16px; }
.form-status { margin: 14px 0 0; font-size: 14px; min-height: 1.4em; }
.form-status.ok { color: var(--accent); }
.form-status.err { color: #a5432f; }

/* ---------- Map ---------- */
.map-card {
  grid-column: 1 / -1;
  position: relative;
  background: var(--surface);
  border-radius: var(--radius-lg);
  overflow: hidden;
  height: clamp(320px, 32vw, 380px);
}
.map { position: absolute; inset: 0; background: var(--surface); }
.map-label {
  position: absolute; z-index: 500; top: 22px; left: 30px;
  font-family: var(--serif); font-size: 24px; color: var(--ink);
  pointer-events: none;
}
.map-fallback { padding: 80px 30px; }
/* stonowane kafelki, żeby pasowały do palety */
.map .leaflet-tile-pane { filter: grayscale(1) sepia(.12) contrast(.92) brightness(1.02); }
.leaflet-container { font-family: var(--sans); }
.map-pin {
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(48, 71, 59, .18);
}
.map-pin.alt { background: var(--eukaliptus); box-shadow: 0 0 0 4px rgba(113, 131, 116, .2); }
.leaflet-tooltip.map-tip {
  background: var(--white); color: var(--ink);
  border: 0; border-radius: 8px;
  box-shadow: 0 4px 16px -6px rgba(0,0,0,.25);
  padding: 7px 11px;
  font-size: 12px; line-height: 1.35;
}
.leaflet-tooltip.map-tip strong { font-weight: 600; }
.leaflet-tooltip-right.map-tip::before { border-right-color: var(--white); }
.leaflet-control-attribution { font-size: 10px; background: rgba(251,251,248,.8) !important; }

/* ---------- Footer ---------- */
.site-footer { background: var(--accent); color: var(--white); padding: 40px 0; }
.site-footer .brand-name { color: var(--white); display: block; margin-bottom: 6px; font-size: 28px; }
.site-footer .brand-sub { color: rgba(251,251,248,.75); font-size: 13px; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 24px; }
.footer-contact { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; font-size: 14px; }
.footer-contact a { text-decoration: none; }
.footer-contact a:hover { text-decoration: underline; }
.footer-contact small { color: rgba(251,251,248,.65); font-size: 12px; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .about-grid, .contact-grid { grid-template-columns: 1fr; }
  .about-media { display: contents; }
  .about-media > picture { order: 1; }
  .about-text { order: 2; }
  .cert { order: 3; margin-top: 8px; }
}
@media (max-width: 720px) {
  .header-inner { min-height: 84px; }
  .brand-name { font-size: 28px; }
  .nav-toggle { display: flex; }
  .site-nav {
    position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; gap: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    padding: 8px var(--gutter) 16px;
    display: none;
  }
  .site-nav.open { display: flex; }
  .site-nav a { padding: 12px 0; font-size: 17px; }
  .hero { min-height: auto; padding: 120px 0 96px; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
  .footer-contact { align-items: flex-start; }
  .map-label { left: 20px; top: 16px; }
}
