/* =========================================================================
   Stolarnia Perełka · Smrek — arkusz stylów
   Kierunek: rzemiosło z Podhala. Świerkowa zieleń (smrek = świerk po góralsku),
   ciepły dąb, kremowy papier. Kroje: Fraunces (nagłówki) + Manrope (tekst).
   Mobile-first, WCAG 2.2 AA (kontrasty sprawdzone skryptem w build.py).
   ========================================================================= */

/* ---------- Tokeny ---------- */
:root {
  --spruce-950: #0f1d16;
  --spruce-900: #14261d;
  --spruce-800: #1b3327;
  --spruce-700: #24443a;
  --moss: #a2bf77;          /* kolor z dotychczasowej identyfikacji — tylko na ciemnym tle */
  --oak: #b4824e;           /* dekoracje, linie */
  --oak-text: #85552a;      /* akcent tekstowy na jasnym tle (kontrast ≥ 5:1) */
  --cream: #f3ece0;
  --paper: #fbf8f2;
  --ink: #1d1f1c;
  --ink-soft: #4a4d47;
  --line: #e2d8c6;
  --white: #fff;

  --font-display: "Fraunces Variable", "Iowan Old Style", Georgia, serif;
  --font-body: "Manrope Variable", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --radius: 14px;
  --radius-lg: 22px;
  --shadow: 0 1px 2px rgba(20, 38, 29, .06), 0 8px 28px rgba(20, 38, 29, .08);
  --shadow-lg: 0 2px 4px rgba(20, 38, 29, .06), 0 22px 50px rgba(20, 38, 29, .14);
  --container: 1200px;
  --gutter: clamp(1.1rem, 4vw, 2rem);
  --section: clamp(4rem, 9vw, 7.5rem);
  --header-h: 72px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 1rem); }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.68;
  color: var(--ink);
  background: var(--paper);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 560;
  line-height: 1.12;
  letter-spacing: -0.015em;
  margin: 0 0 .6em;
  font-variation-settings: "opsz" 96;
  text-wrap: balance;
}
h1 { font-size: clamp(2.25rem, 5.4vw, 4.1rem); }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.75rem); }
h3 { font-size: clamp(1.25rem, 2vw, 1.5rem); font-variation-settings: "opsz" 36; }
p { margin: 0 0 1.1em; text-wrap: pretty; }
ul, ol { margin: 0 0 1.1em; padding-left: 1.2em; }

.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 1rem; top: -100px; z-index: 200;
  background: var(--spruce-900); color: var(--white); padding: .7rem 1rem; border-radius: 8px;
}
.skip-link:focus { top: 1rem; }

:focus-visible { outline: 3px solid var(--oak); outline-offset: 3px; border-radius: 4px; }

.container { width: min(100% - 2 * var(--gutter), var(--container)); margin-inline: auto; }
.section { padding-block: var(--section); }
.section--cream { background: var(--cream); }
.section--dark { background: var(--spruce-900); color: var(--cream); }
.section--dark h2, .section--dark h3 { color: var(--white); }

.eyebrow {
  display: inline-flex; align-items: center; gap: .6rem;
  font-size: .8rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--oak-text); margin-bottom: 1rem;
}
.eyebrow::before { content: ""; width: 28px; height: 2px; background: currentColor; }
.section--dark .eyebrow { color: var(--moss); }
.lead { font-size: clamp(1.1rem, 1.6vw, 1.25rem); color: var(--ink-soft); max-width: 62ch; }
.section--dark .lead { color: #d9d2c4; }
.section-head { max-width: 760px; margin-bottom: clamp(2rem, 5vw, 3.5rem); }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head--center .eyebrow::after { content: ""; width: 28px; height: 2px; background: currentColor; }

/* ---------- Przyciski ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  min-height: 48px; padding: .8rem 1.4rem; border-radius: 999px; border: 2px solid transparent;
  font-weight: 700; font-size: 1rem; text-decoration: none; cursor: pointer;
  transition: transform .2s ease, background-color .2s ease, color .2s ease, border-color .2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn--primary { background: var(--spruce-900); color: var(--white); }
.btn--primary:hover { background: var(--spruce-700); }
.btn--ghost { border-color: var(--spruce-900); color: var(--spruce-900); background: transparent; }
.btn--ghost:hover { background: var(--spruce-900); color: var(--white); }
.btn--light { background: var(--cream); color: var(--spruce-900); }
.btn--light:hover { background: var(--white); }
.btn--outline-light { border-color: rgba(243, 236, 224, .6); color: var(--cream); }
.btn--outline-light:hover { background: var(--cream); color: var(--spruce-900); }
.btn svg { width: 1.15em; height: 1.15em; flex: none; }

.link-arrow {
  display: inline-flex; align-items: center; gap: .4rem; font-weight: 700; color: var(--spruce-900);
  text-decoration: none; border-bottom: 2px solid var(--oak); padding-bottom: 2px;
}
.link-arrow::after { content: "→"; transition: transform .2s ease; }
.link-arrow:hover::after { transform: translateX(4px); }

/* ---------- Nagłówek ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(251, 248, 242, .9);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s ease, box-shadow .3s ease;
}
.site-header.is-scrolled { border-bottom-color: var(--line); box-shadow: 0 6px 20px rgba(20, 38, 29, .06); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: var(--header-h); }

.brand { display: inline-flex; align-items: center; gap: .7rem; text-decoration: none; color: var(--spruce-900); }
.brand svg { width: 40px; height: 40px; flex: none; }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-name { font-family: var(--font-display); font-size: 1.45rem; font-weight: 600; letter-spacing: -0.01em; }
.brand-sub { font-size: .68rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--oak-text); margin-top: 3px; }

.nav-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--white); cursor: pointer;
}
.nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after {
  display: block; width: 20px; height: 2px; background: var(--spruce-900); border-radius: 2px; position: relative;
  transition: transform .25s ease, opacity .25s ease;
}
.nav-toggle-bars::before, .nav-toggle-bars::after { content: ""; position: absolute; left: 0; }
.nav-toggle-bars::before { top: -6px; }
.nav-toggle-bars::after { top: 6px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::after { transform: translateY(-6px) rotate(-45deg); }

.site-nav { display: none; }
.site-nav ul { list-style: none; margin: 0; padding: 0; }
.site-nav a { text-decoration: none; font-weight: 600; }
.site-nav a[aria-current="page"] { color: var(--oak-text); }

/* Menu mobilne */
.site-nav.is-open {
  display: block; position: absolute; inset: var(--header-h) 0 auto 0;
  background: var(--paper); border-bottom: 1px solid var(--line); box-shadow: var(--shadow-lg);
  padding: .5rem var(--gutter) 1.5rem; max-height: calc(100dvh - var(--header-h)); overflow-y: auto;
}
.site-nav.is-open li { border-bottom: 1px solid var(--line); }
.site-nav.is-open a { display: block; padding: 1rem .25rem; font-size: 1.1rem; }
.header-cta { display: none; }

@media (min-width: 1080px) {
  .nav-toggle { display: none; }
  .site-nav, .site-nav.is-open { display: block; position: static; box-shadow: none; border: 0; padding: 0; background: none; max-height: none; }
  .site-nav ul { display: flex; gap: clamp(.9rem, 1.8vw, 1.8rem); }
  .site-nav.is-open li { border: 0; }
  .site-nav a, .site-nav.is-open a { display: inline-block; padding: .4rem 0; font-size: .97rem; position: relative; }
  .site-nav a::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--oak);
    transform: scaleX(0); transform-origin: left; transition: transform .25s ease;
  }
  .site-nav a:hover::after, .site-nav a[aria-current="page"]::after { transform: scaleX(1); }
  .header-cta { display: inline-flex; min-height: 44px; padding: .55rem 1.1rem; font-size: .95rem; }
}

/* ---------- Hero (strona główna) ---------- */
.hero { padding-block: clamp(2.5rem, 6vw, 5rem) clamp(3.5rem, 8vw, 6rem); position: relative; overflow: hidden; }
.hero::before {
  /* delikatne „słoje" w tle */
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background:
    radial-gradient(120% 70% at 100% 0%, rgba(180, 130, 78, .12), transparent 60%),
    radial-gradient(90% 60% at 0% 100%, rgba(36, 68, 58, .08), transparent 60%);
}
.hero-grid { display: grid; gap: clamp(2rem, 5vw, 4rem); align-items: center; position: relative; }
.hero h1 em { font-style: italic; color: var(--oak-text); font-weight: 480; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin: 2rem 0 2.2rem; }
.hero-facts {
  list-style: none; padding: 0; margin: 0; display: grid; gap: .75rem 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); font-size: .95rem; color: var(--ink-soft);
}
.hero-facts li { display: flex; gap: .6rem; align-items: flex-start; }
.hero-facts svg { width: 20px; height: 20px; flex: none; color: var(--oak); margin-top: 3px; }
.hero-facts strong { color: var(--ink); display: block; }

.hero-media { position: relative; }
.arch {
  /* łuk — nawiązanie do okien sakralnych i góralskich portali */
  border-radius: 999px 999px var(--radius-lg) var(--radius-lg);
  overflow: hidden; aspect-ratio: 4 / 5; background: var(--cream); box-shadow: var(--shadow-lg);
}
.arch img { width: 100%; height: 100%; object-fit: cover; }
.hero-badge {
  position: absolute; left: -0.5rem; bottom: 1.5rem; background: var(--spruce-900); color: var(--cream);
  border-radius: var(--radius); padding: 1rem 1.2rem; box-shadow: var(--shadow-lg); max-width: 230px; font-size: .9rem; line-height: 1.4;
}
.hero-badge strong { display: block; font-family: var(--font-display); font-size: 1.3rem; color: var(--white); font-weight: 560; margin-bottom: .2rem; }
.hero-ornament { position: absolute; right: -14px; top: -14px; width: 92px; height: 92px; color: var(--oak); opacity: .9; }

@media (min-width: 900px) {
  .hero-grid { grid-template-columns: 1.08fr .92fr; }
  .hero-badge { left: -2rem; }
}

/* ---------- Hero podstron ---------- */
.page-hero { padding-block: clamp(1.5rem, 4vw, 3rem) clamp(3rem, 6vw, 4.5rem); }
.page-hero-grid { display: grid; gap: clamp(1.8rem, 4vw, 3.5rem); align-items: center; }
.page-hero .arch { aspect-ratio: 5 / 4; border-radius: 240px 240px var(--radius-lg) var(--radius-lg); }
@media (min-width: 900px) { .page-hero-grid { grid-template-columns: 1.15fr .85fr; } }
.page-hero--plain .page-hero-grid { grid-template-columns: 1fr; max-width: 820px; }

/* ---------- Okruszki ---------- */
.breadcrumbs ol { list-style: none; padding: 0; margin: 0 0 1.6rem; display: flex; flex-wrap: wrap; gap: .4rem; font-size: .88rem; color: var(--ink-soft); }
.breadcrumbs li + li::before { content: "/"; margin-right: .4rem; color: var(--oak); }
.breadcrumbs a { text-decoration: none; }
.breadcrumbs a:hover { text-decoration: underline; }

/* ---------- Karty oferty ---------- */
.cards { display: grid; gap: clamp(1.2rem, 2.5vw, 1.8rem); grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
.card {
  background: var(--white); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow);
  display: flex; flex-direction: column; transition: transform .3s ease, box-shadow .3s ease; position: relative;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.card-media { aspect-ratio: 4 / 3; background: var(--cream); overflow: hidden; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.card:hover .card-media img { transform: scale(1.04); }
.card-body { padding: 1.4rem 1.4rem 1.6rem; display: flex; flex-direction: column; gap: .2rem; flex: 1; }
.card-body p { color: var(--ink-soft); font-size: .98rem; }
.card-body .link-arrow { margin-top: auto; align-self: flex-start; }
.card h3 a { text-decoration: none; }
.card h3 a::after { content: ""; position: absolute; inset: 0; } /* cała karta klikalna, jeden link */

/* ---------- Proces ---------- */
.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 1.5rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); counter-reset: step; }
.step { padding: 1.6rem; border-top: 2px solid var(--oak); counter-increment: step; }
.step::before {
  content: counter(step, decimal-leading-zero); display: block; font-family: var(--font-display);
  font-size: 2.6rem; line-height: 1; color: var(--oak-text); margin-bottom: .8rem; font-variation-settings: "opsz" 144; font-weight: 400;
}
.section--dark .step::before { color: var(--moss); }
.step p { color: var(--ink-soft); font-size: .98rem; margin: 0; }
.section--dark .step p { color: #d9d2c4; }

/* ---------- Atuty / lista z ikonami ---------- */
.features { display: grid; gap: 1.2rem 2rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); list-style: none; padding: 0; margin: 0; }
.feature { display: flex; gap: 1rem; }
.feature-icon {
  width: 48px; height: 48px; border-radius: 12px; display: grid; place-items: center; flex: none;
  background: var(--cream); color: var(--spruce-800);
}
.section--cream .feature-icon { background: var(--white); }
.feature-icon svg { width: 24px; height: 24px; }
.feature h3 { font-size: 1.15rem; margin-bottom: .3rem; }
.feature p { color: var(--ink-soft); font-size: .97rem; margin: 0; }

/* ---------- Dwie kolumny ---------- */
.split { display: grid; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
@media (min-width: 900px) {
  .split { grid-template-columns: 1fr 1fr; }
  .split--reverse > :first-child { order: 2; }
}
.split-media { border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 4 / 3; box-shadow: var(--shadow-lg); background: var(--cream); }
.split-media img { width: 100%; height: 100%; object-fit: cover; }
.checklist { list-style: none; padding: 0; margin: 0 0 1.6rem; display: grid; gap: .65rem; }
.checklist li { position: relative; padding-left: 2rem; }
.checklist li::before {
  content: ""; position: absolute; left: 0; top: .35em; width: 1.15rem; height: 1.15rem; border-radius: 50%;
  background: var(--spruce-800) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 70% no-repeat;
}
.section--dark .checklist li::before { background-color: var(--moss); }

/* ---------- Opowieść o smreku ---------- */
.story { position: relative; overflow: hidden; }
.story-tree { position: absolute; right: -40px; bottom: -30px; width: min(42vw, 420px); color: var(--spruce-700); opacity: .55; pointer-events: none; }
.story .container { position: relative; }
.story blockquote {
  margin: 0; font-family: var(--font-display); font-size: clamp(1.5rem, 3vw, 2.2rem); line-height: 1.3;
  font-weight: 420; color: var(--white); max-width: 26ch; font-variation-settings: "opsz" 144;
}
.story blockquote em { color: var(--moss); }

/* ---------- Galeria ---------- */
.gallery-filters { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 2rem; }
.chip {
  border: 1.5px solid var(--line); background: var(--white); border-radius: 999px; padding: .55rem 1.05rem;
  min-height: 44px; font-weight: 600; font-size: .93rem; cursor: pointer; transition: all .2s ease;
}
.chip:hover { border-color: var(--spruce-800); }
.chip[aria-pressed="true"] { background: var(--spruce-900); border-color: var(--spruce-900); color: var(--white); }
.gallery { display: grid; gap: clamp(.6rem, 1.5vw, 1rem); grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); list-style: none; padding: 0; margin: 0; }
.gallery figure { margin: 0; }
.gallery button { all: unset; display: block; width: 100%; cursor: zoom-in; border-radius: var(--radius); overflow: hidden; aspect-ratio: 1; background: var(--cream); }
.gallery button:focus-visible { outline: 3px solid var(--oak); outline-offset: 3px; }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.gallery button:hover img { transform: scale(1.05); }
.gallery figcaption { font-size: .88rem; color: var(--ink-soft); padding: .5rem .2rem 0; }
.gallery li[hidden] { display: none; }
.gallery--teaser { grid-template-columns: repeat(2, 1fr); }
@media (min-width: 760px) { .gallery--teaser { grid-template-columns: repeat(3, 1fr); } }


/* ---------- FAQ ---------- */
.faq { max-width: 860px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; padding: 1.3rem 2.5rem 1.3rem 0; position: relative;
  font-family: var(--font-display); font-size: clamp(1.1rem, 1.8vw, 1.3rem); font-weight: 520; font-variation-settings: "opsz" 36;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: .2rem; top: 50%; translate: 0 -50%; font-family: var(--font-body);
  font-size: 1.6rem; font-weight: 400; color: var(--oak-text); transition: rotate .25s ease;
}
.faq details[open] summary::after { rotate: 45deg; }
.faq .faq-answer { padding: 0 0 1.4rem; color: var(--ink-soft); max-width: 70ch; }

/* ---------- CTA ---------- */
.cta-band { background: var(--spruce-900); color: var(--cream); border-radius: var(--radius-lg); padding: clamp(2rem, 5vw, 3.5rem); display: grid; gap: 1.5rem; align-items: center; position: relative; overflow: hidden; }
.cta-band h2 { color: var(--white); margin-bottom: .3em; }
.cta-band p { color: #d9d2c4; margin: 0; }
.cta-band .actions { display: flex; flex-wrap: wrap; gap: .8rem; }
@media (min-width: 900px) { .cta-band { grid-template-columns: 1.4fr 1fr; } .cta-band .actions { justify-content: flex-end; } }

/* ---------- Treść (prose) ---------- */
.prose { max-width: 72ch; }
.prose h2 { margin-top: 1.6em; font-size: clamp(1.5rem, 2.6vw, 2rem); }
.prose h3 { margin-top: 1.4em; }
.prose a { color: var(--spruce-800); text-decoration-color: var(--oak); text-underline-offset: 3px; }

/* ---------- Kontakt ---------- */
.contact-grid { display: grid; gap: clamp(2rem, 5vw, 4rem); }
@media (min-width: 960px) { .contact-grid { grid-template-columns: .9fr 1.1fr; } }
.contact-card { background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow); padding: clamp(1.5rem, 3vw, 2.2rem); }
.contact-list { list-style: none; padding: 0; margin: 0 0 1.5rem; display: grid; gap: 1.1rem; }
.contact-list li { display: flex; gap: .9rem; }
.contact-list .feature-icon { width: 44px; height: 44px; }
.contact-list strong { display: block; font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--oak-text); }
.contact-list a { font-weight: 700; text-decoration: none; }
.contact-list a:hover { text-decoration: underline; }
.map-embed { border-radius: var(--radius-lg); overflow: hidden; background: var(--cream); aspect-ratio: 16 / 10; display: grid; place-items: center; text-align: center; padding: 1.5rem; border: 1px dashed var(--oak); }
.map-embed iframe { width: 100%; height: 100%; border: 0; }
.map-embed.is-loaded { padding: 0; border: 0; }

/* ---------- Formularz ---------- */
.form { display: grid; gap: 1.1rem; }
.form-row { display: grid; gap: 1.1rem; }
@media (min-width: 640px) { .form-row { grid-template-columns: 1fr 1fr; } }
.field { display: grid; gap: .4rem; }
.field label { font-weight: 700; font-size: .95rem; }
.field .hint { font-size: .85rem; color: var(--ink-soft); }
.field input, .field select, .field textarea {
  width: 100%; min-height: 50px; padding: .8rem 1rem; border: 1.5px solid #cfc3ae; border-radius: 12px; background: var(--paper);
  transition: border-color .2s ease, box-shadow .2s ease;
}
.field textarea { min-height: 150px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--spruce-800); box-shadow: 0 0 0 4px rgba(36, 68, 58, .18); }
.field input:user-invalid, .field textarea:user-invalid { border-color: #a23b2a; }
.consent { display: flex; gap: .7rem; align-items: flex-start; font-size: .9rem; color: var(--ink-soft); }
.consent input { width: 22px; height: 22px; margin-top: 2px; flex: none; accent-color: var(--spruce-900); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { padding: 1rem 1.2rem; border-radius: 12px; font-weight: 600; }
.form-status:empty { display: none; }
.form-status.is-success { background: #e4efd8; color: #22401b; }
.form-status.is-error { background: #f7e1dc; color: #7a2516; }
.form-note { font-size: .85rem; color: var(--ink-soft); }

/* ---------- Stopka ---------- */
.site-footer { background: var(--spruce-950); color: #cfc8b9; padding-block: clamp(3.5rem, 7vw, 5rem) 2rem; font-size: .95rem; }
.site-footer a { color: var(--cream); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.footer-grid { display: grid; gap: 2.5rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); }
.site-footer h2 { font-size: 1rem; font-family: var(--font-body); font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--moss); margin-bottom: 1rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: .5rem; }
.site-footer address { font-style: normal; line-height: 1.8; }
.site-footer .brand { color: var(--cream); margin-bottom: 1rem; }
.site-footer .brand-sub { color: var(--moss); }
.footer-bottom { border-top: 1px solid rgba(207, 200, 185, .18); margin-top: 3rem; padding-top: 1.5rem; display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; font-size: .85rem; }
.footer-bottom button { background: none; border: 0; padding: 0; color: var(--cream); cursor: pointer; text-decoration: underline; font-size: inherit; }

/* ---------- Pasek telefonu (mobile) ---------- */
.mobile-call {
  position: fixed; left: 1rem; right: 1rem; bottom: 1rem; z-index: 90; display: flex; gap: .6rem;
  transform: translateY(150%); transition: transform .35s ease;
}
.mobile-call.is-visible { transform: none; }
.mobile-call .btn { flex: 1; box-shadow: var(--shadow-lg); }
@media (min-width: 1080px) { .mobile-call { display: none; } }

/* ---------- Baner cookies ---------- */
.cookie-banner {
  position: fixed; z-index: 150; left: 1rem; right: 1rem; bottom: 1rem; max-width: 560px; margin-inline: auto;
  background: var(--white); color: var(--ink); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
  padding: 1.4rem 1.5rem; border: 1px solid var(--line);
}
.cookie-banner h2 { font-size: 1.2rem; margin-bottom: .4rem; }
.cookie-banner p { font-size: .92rem; color: var(--ink-soft); margin-bottom: 1rem; }
.cookie-banner .actions { display: flex; flex-wrap: wrap; gap: .6rem; }
.cookie-banner .btn { flex: 1 1 140px; min-height: 46px; padding: .6rem 1rem; font-size: .95rem; }
.cookie-banner[hidden] { display: none; }

/* ---------- Animacje przy przewijaniu (tylko z JS, treść zawsze dostępna bez JS) ---------- */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
.js .reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ---------- Pomocnicze ---------- */
.mt-0 { margin-top: 0; }
.center { text-align: center; }
.stack-lg > * + * { margin-top: clamp(3rem, 6vw, 5rem); }
.tags { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; padding: 0; margin: 0 0 1.5rem; }
.tags li { background: var(--cream); border-radius: 999px; padding: .35rem .85rem; font-size: .88rem; font-weight: 600; color: var(--spruce-800); }
.section--cream .tags li { background: var(--white); }

@media print {
  .site-header, .mobile-call, .cookie-banner, .site-footer .footer-bottom button { display: none !important; }
  body { background: #fff; }
}

/* =========================================================================
   WARSTWA RUCHU — „warsztat w ruchu"
   Efekty inspirowane pracą stolarza: słoje rysujące się w tle, rozeta wycinana dłutem,
   heblowanie (odsłanianie) zdjęć, miarka jako pasek postępu, połysk lakieru, linia cięcia.
   Zasady: tylko transform/opacity/clip-path (60 fps, dobre INP), treść zawsze widoczna bez JS,
   pełne wyłączenie przy prefers-reduced-motion.
   ========================================================================= */
:root {
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-plane: cubic-bezier(.77, 0, .18, 1);
  /* tekstura słojów (feTurbulence rozciągnięty w poziomie = włókna drewna) */
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='800' height='400'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.006 .22' numOctaves='3' seed='11'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .07 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23g)'/%3E%3C/svg%3E");
  --oak-grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='600' height='300'%3E%3Cfilter id='o'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.004 .18' numOctaves='4' seed='4'/%3E%3CfeColorMatrix values='0 0 0 0 .42 0 0 0 0 .26 0 0 0 0 .12 0 0 0 .55 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' fill='%23b4824e'/%3E%3Crect width='100%25' height='100%25' filter='url(%23o)'/%3E%3C/svg%3E");
}
::selection { background: var(--oak); color: var(--white); }

/* ---------- Przejścia między podstronami (View Transitions API, zero JS) ---------- */
@view-transition { navigation: auto; }
.site-header { view-transition-name: naglowek; }
::view-transition-old(root) { animation: vt-out .35s var(--ease-out) both; }
::view-transition-new(root) { animation: vt-in .55s var(--ease-out) both; }
@keyframes vt-out { to { opacity: 0; transform: translateY(-12px); } }
@keyframes vt-in { from { opacity: 0; transform: translateY(18px); } }

/* ---------- Faktura drewna na ciemnych sekcjach ---------- */
.section--dark, .cta-band, .site-footer { background-image: var(--grain); background-size: 800px 400px; }

/* ---------- Miarka stolarska = pasek postępu przewijania ---------- */
.tape {
  position: fixed; inset: 0 0 auto 0; height: 7px; z-index: 120; pointer-events: none;
  background: repeating-linear-gradient(90deg, rgba(20, 38, 29, .35) 0 1px, transparent 1px 10px) bottom / 100% 4px no-repeat;
}
.tape span {
  display: block; height: 100%; transform-origin: 0 50%; transform: scaleX(var(--p, 0));
  background: linear-gradient(90deg, #d8b25a, #e9c46a 60%, #d8b25a);
  background-image: repeating-linear-gradient(90deg, rgba(20, 38, 29, .55) 0 1px, transparent 1px 10px),
                    repeating-linear-gradient(90deg, rgba(20, 38, 29, .7) 0 2px, transparent 2px 50px),
                    linear-gradient(90deg, #d8b25a, #ebc76c);
  box-shadow: 0 1px 4px rgba(0, 0, 0, .15);
}

/* ---------- Nagłówek chowa się przy przewijaniu w dół ---------- */
.site-header { transition: transform .45s var(--ease-out), border-color .3s ease, box-shadow .3s ease; }
.site-header.is-hidden { transform: translateY(-100%); }

/* ---------- Hero: słoje drewna rysowane w tle ---------- */
.hero-rings {
  position: absolute; inset: 0; width: 100%; height: 100%; color: var(--oak); opacity: .24; pointer-events: none;
  transform: translate3d(0, calc(var(--sy, 0) * .15px), 0);
}
.hero-rings path { stroke-dasharray: 1; stroke-dashoffset: 0; }
.js .hero-rings path { stroke-dashoffset: 1; animation: draw 2.6s var(--ease-out) forwards; animation-delay: calc(var(--i) * 90ms); }
@keyframes draw { to { stroke-dashoffset: 0; } }

/* Rozeta: „wycinanie" konturu, potem powolny obrót */
.hero-ornament circle { stroke-dasharray: 1; }
.js .hero-ornament { animation: spin 90s linear infinite; }
.js .hero-ornament circle { stroke-dasharray: 260; stroke-dashoffset: 260; animation: draw 2.2s .4s var(--ease-out) forwards; }
@keyframes spin { to { rotate: 360deg; } }

/* Wejście treści hero — bez opacity:0 na H1, by nie opóźniać LCP */
.js .hero .eyebrow, .js .hero .lead, .js .hero-actions, .js .hero-facts li, .js .hero-badge {
  animation: rise .9s var(--ease-out) both;
}
.js .hero .lead { animation-delay: .25s; }
.js .hero-actions { animation-delay: .38s; }
.js .hero-facts li:nth-child(1) { animation-delay: .5s; }
.js .hero-facts li:nth-child(2) { animation-delay: .6s; }
.js .hero-facts li:nth-child(3) { animation-delay: .7s; }
.js .hero-badge { animation-delay: 1.1s; }
@keyframes rise { from { opacity: 0; transform: translateY(22px); } }

.js .hero h1 .w { display: inline-block; animation: lift 1s var(--ease-out) both; animation-delay: calc(var(--w) * 55ms); }
@keyframes lift { from { transform: translateY(.35em) rotate(1.5deg); } }

/* „Drewniany" tekst: słoje w literach + przesuwający się połysk */
.hero h1 em, .footer-mark em {
  background: linear-gradient(100deg, transparent 40%, rgba(255, 240, 210, .75) 50%, transparent 60%) 200% 0 / 250% 100% no-repeat,
              var(--oak-grain) 0 0 / 600px 300px;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  -webkit-text-fill-color: transparent;
  padding-right: .05em;
}
.js .hero h1 em { animation: sheen 3.2s 1.2s var(--ease-out) both; }
@keyframes sheen { from { background-position: 200% 0, 0 0; } to { background-position: -100% 0, 0 0; } }
@supports not (background-clip: text) { .hero h1 em, .footer-mark em { color: var(--oak-text); -webkit-text-fill-color: currentColor; } }

/* Delikatny parallax zdjęcia hero */
.hero .arch img { transform: translate3d(0, calc(var(--sy, 0) * -.06px), 0) scale(1.08); }

/* ---------- Heblowanie: zdjęcie odsłaniane spod deski ---------- */
.wood-reveal { position: relative; isolation: isolate; }
.js .wood-reveal::after {
  content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none;
  background: var(--oak-grain) 0 0 / 600px 300px;
  transform-origin: 100% 50%; transition: transform 1.15s var(--ease-plane);
}
.js .wood-reveal::before { /* „wiór" — jasna krawędź struga przesuwająca się z deską */
  content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 14px; z-index: 3; pointer-events: none;
  background: linear-gradient(90deg, rgba(255, 236, 200, 0), rgba(255, 236, 200, .9), rgba(255, 236, 200, 0));
  opacity: 0; transform: translateX(-20px);
}
.js .wood-reveal img { transform: scale(1.14); transition: transform 1.6s var(--ease-out); }
.js .wood-reveal.is-visible::after { transform: scaleX(0); }
.js .wood-reveal.is-visible::before { animation: shaving 1.15s var(--ease-plane) forwards; }
.js .wood-reveal.is-visible img { transform: scale(1); }
.js .hero .wood-reveal.is-visible img { transform: translate3d(0, calc(var(--sy, 0) * -.06px), 0) scale(1.08); }
@keyframes shaving { 0% { opacity: 1; left: 0; } 100% { opacity: 0; left: 100%; } }
.card:hover .card-media.is-visible img, .js .card:hover .wood-reveal.is-visible img { transform: scale(1.05); }

/* ---------- Karty: przechył 3D + połysk lakieru za kursorem ---------- */
@media (hover: hover) and (pointer: fine) {
  .card { transform-style: preserve-3d; will-change: transform; }
  .card.is-tilting { transition: transform .12s linear, box-shadow .3s ease; transform: perspective(900px) rotateX(var(--rx, 0)) rotateY(var(--ry, 0)) translateY(-4px); }
  .card::before {
    content: ""; position: absolute; inset: 0; z-index: 4; pointer-events: none; border-radius: inherit; opacity: 0;
    background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgba(255, 244, 222, .28), transparent 45%);
    transition: opacity .3s ease;
  }
  .card:hover::before { opacity: 1; }
}

/* ---------- Przyciski: przejście połysku (lakier) ---------- */
.btn { position: relative; overflow: hidden; isolation: isolate; }
.btn::before {
  content: ""; position: absolute; inset: -2px; z-index: -1; pointer-events: none;
  background: linear-gradient(115deg, transparent 35%, rgba(255, 255, 255, .35) 50%, transparent 65%);
  transform: translateX(-110%); transition: transform .8s var(--ease-out);
}
.btn:hover::before { transform: translateX(110%); }
.btn--ghost::before, .btn--outline-light::before { background: linear-gradient(115deg, transparent 35%, rgba(180, 130, 78, .25) 50%, transparent 65%); }
.btn:active { transform: translateY(0) scale(.98); }

/* ---------- Eyebrow: linia rośnie jak rysowana ołówkiem stolarskim ---------- */
.js .reveal .eyebrow::before, .js .section-head.reveal .eyebrow::before { width: 0; transition: width .9s .2s var(--ease-out); }
.js .reveal.is-visible .eyebrow::before { width: 28px; }

/* ---------- Proces: linia cięcia piłą + numeracja ---------- */
.step { position: relative; border-top-color: transparent; }
.step::after {
  content: ""; position: absolute; top: -2px; left: 0; right: 0; height: 2px;
  background: repeating-linear-gradient(90deg, var(--oak) 0 10px, transparent 10px 16px);
  transform-origin: 0 50%;
}
.section--dark .step::after { background: repeating-linear-gradient(90deg, var(--moss) 0 10px, transparent 10px 16px); }
.js .step.reveal::after { transform: scaleX(0); transition: transform 1.1s var(--ease-plane); transition-delay: inherit; }
.js .step.reveal.is-visible::after { transform: scaleX(1); }

/* ---------- Kaskadowe pojawianie (opóźnienie ustawia JS: --d) ---------- */
.js .reveal { transition-delay: var(--d, 0ms); }

/* ---------- Pasek z zakresem prac (marquee) ---------- */
.marquee {
  overflow: hidden; background: var(--spruce-900); color: var(--cream); padding-block: 1.1rem;
  background-image: var(--grain); background-size: 800px 400px;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee-track { display: flex; width: max-content; animation: marquee 48s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-group { display: flex; align-items: center; gap: 2.2rem; padding-right: 2.2rem; }
.marquee-group span { font-family: var(--font-display); font-style: italic; font-weight: 380; font-size: clamp(1.4rem, 3vw, 2.2rem); white-space: nowrap; font-variation-settings: "opsz" 144; }
.marquee-group span:nth-of-type(even) { color: transparent; -webkit-text-stroke: 1px var(--moss); }
.marquee svg { width: 18px; height: 18px; color: var(--oak); flex: none; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Drzewo w sekcji „Smrek": rysowanie konturu ---------- */
.story-tree path { stroke-dasharray: 1200; stroke-dashoffset: 0; }
.js .story-tree path { stroke-dashoffset: 1200; transition: stroke-dashoffset 3s var(--ease-out); }
.js .story.is-visible .story-tree path { stroke-dashoffset: 0; }

/* ---------- Galeria: rozpakowanie lightboxa ---------- */
.gallery button { position: relative; }
.gallery button::after {
  content: "+"; position: absolute; right: .7rem; bottom: .7rem; width: 38px; height: 38px; border-radius: 50%;
  display: grid; place-items: center; font-size: 1.4rem; background: rgba(251, 248, 242, .92); color: var(--spruce-900);
  opacity: 0; transform: scale(.6) rotate(-90deg); transition: all .35s var(--ease-out);
}
.gallery button:hover::after, .gallery button:focus-visible::after { opacity: 1; transform: none; }

/* ---------- Duży znak w stopce ---------- */
.footer-mark {
  font-family: var(--font-display); font-weight: 420; font-size: clamp(2.6rem, 9vw, 7.5rem); line-height: 1; letter-spacing: -.03em;
  color: var(--cream); margin: 0 0 clamp(2.5rem, 5vw, 4rem); padding-bottom: clamp(2rem, 4vw, 3rem);
  border-bottom: 1px solid rgba(207, 200, 185, .18); font-variation-settings: "opsz" 144;
}
.footer-mark em { font-style: italic; }

/* ---------- FAQ: płynne otwieranie ---------- */
.faq details::details-content { block-size: 0; overflow: hidden; transition: block-size .45s var(--ease-out), content-visibility .45s allow-discrete; }
.faq details[open]::details-content { block-size: auto; }
:root { interpolate-size: allow-keywords; }

/* ---------- Szacunek dla ustawień systemowych ---------- */
@media (prefers-reduced-motion: reduce) {
  .js .hero-rings path, .js .hero-ornament circle, .js .story-tree path { stroke-dashoffset: 0 !important; animation: none !important; transition: none !important; }
  .js .hero-ornament, .marquee-track, .js .hero h1 .w, .js .hero h1 em { animation: none !important; }
  .js .wood-reveal::after, .js .wood-reveal::before { display: none; }
  .js .wood-reveal img, .hero .arch img, .hero-rings { transform: none !important; }
  .card.is-tilting { transform: none !important; }
  .site-header.is-hidden { transform: none; }
  @view-transition { navigation: none; }
}

/* Staging subdomain ribbon (APP_ENV=staging) */
.staging-ribbon { position: relative; z-index: 130; background: #e9c46a; color: #14261d; text-align: center; font-size: .85rem; font-weight: 700; padding: .35rem 1rem; }

/* =========================================================================
   LIGHTBOX — pełnoekranowa „pracownia" do oglądania realizacji
   ========================================================================= */
html.lb-open { overflow: hidden; }
.lightbox {
  width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0;
  color: var(--cream); background: #0c1611 var(--grain); background-size: 800px 400px; overflow: hidden;
}
.lightbox[open] {
  display: grid; grid-template-rows: auto minmax(0, 1fr) auto auto; grid-template-columns: 100%;
  animation: lb-open .45s var(--ease-out);
}
.lightbox::backdrop { background: rgba(8, 15, 11, .85); }
@keyframes lb-open { from { opacity: 0; transform: scale(.985); } }

.lb-top { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .9rem clamp(1rem, 3vw, 2rem); }
.lb-meta { margin: 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: .4rem 1rem; }
.lb-counter { font-family: var(--font-display); font-size: 1.15rem; font-variation-settings: "opsz" 36; }
.lb-cat { font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--moss); }
.lb-tools { display: flex; gap: .5rem; }

.lb-btn {
  width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; cursor: pointer;
  border: 1px solid rgba(243, 236, 224, .28); background: rgba(243, 236, 224, .08); color: var(--cream);
  transition: background-color .2s ease, transform .2s ease, border-color .2s ease;
}
.lb-btn:hover { background: var(--cream); color: var(--spruce-900); border-color: var(--cream); }
.lb-btn:active { transform: scale(.94); }
.lb-btn:focus-visible { outline: 3px solid var(--oak); outline-offset: 3px; }
.lb-btn svg { width: 24px; height: 24px; }
.lb-zoom[aria-pressed="true"] { background: var(--cream); color: var(--spruce-900); }

.lb-stage { position: relative; margin: 0; min-height: 0; display: grid; place-items: center; padding: 0 clamp(.5rem, 7vw, 6.5rem); overflow: hidden; touch-action: pan-y; }
.lb-img {
  max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; border-radius: 10px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .55); cursor: zoom-in; user-select: none; -webkit-user-drag: none;
  transition: opacity .35s ease, transform .45s var(--ease-out), filter .35s ease;
}
.lightbox.is-loading .lb-img { opacity: .15; filter: blur(6px); }
.lightbox.is-loading[data-dir="next"] .lb-img { transform: translateX(28px); }
.lightbox.is-loading[data-dir="prev"] .lb-img { transform: translateX(-28px); }
.lightbox.is-zoomed .lb-img { transform: scale(2); cursor: zoom-out; box-shadow: none; }
.lb-spinner {
  position: absolute; width: 44px; height: 44px; border-radius: 50%; opacity: 0; pointer-events: none;
  border: 3px solid rgba(243, 236, 224, .2); border-top-color: var(--moss); animation: lb-spin .8s linear infinite; transition: opacity .2s;
}
.lightbox.is-loading .lb-spinner { opacity: 1; transition-delay: .25s; }
@keyframes lb-spin { to { rotate: 360deg; } }

.lb-nav { position: absolute; top: 50%; translate: 0 -50%; z-index: 2; width: 60px; height: 60px; background: rgba(12, 22, 17, .55); backdrop-filter: blur(6px); }
.lb-prev { left: clamp(.5rem, 2vw, 1.5rem); }
.lb-next { right: clamp(.5rem, 2vw, 1.5rem); }
.lightbox.is-single .lb-nav, .lightbox.is-single .lb-strip { display: none; }

.lb-bottom {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .6rem 1.5rem;
  padding: .9rem clamp(1rem, 3vw, 2rem) .4rem; max-width: 1200px; width: 100%; margin-inline: auto;
}
.lb-caption { margin: 0; font-size: 1rem; color: #e4ddcf; max-width: 70ch; }
.lb-cta { color: var(--cream); font-weight: 700; text-decoration: none; border-bottom: 2px solid var(--oak); padding: .45rem 0; white-space: nowrap; }
.lb-cta:hover { color: #fff; border-color: var(--moss); }

.lb-strip {
  display: flex; gap: .5rem; overflow-x: auto; padding: .6rem clamp(1rem, 3vw, 2rem) max(1rem, env(safe-area-inset-bottom));
  scrollbar-width: thin; scrollbar-color: rgba(243, 236, 224, .3) transparent; justify-content: safe center;
}
.lb-strip button {
  flex: none; width: 72px; height: 54px; padding: 0; border-radius: 8px; overflow: hidden; cursor: pointer;
  border: 2px solid transparent; background: #1b3327; opacity: .55; transition: opacity .2s, border-color .2s, transform .2s;
}
.lb-strip button:hover { opacity: .9; }
.lb-strip button[aria-current="true"] { opacity: 1; border-color: var(--moss); transform: translateY(-2px); }
.lb-strip button:focus-visible { outline: 3px solid var(--oak); outline-offset: 2px; opacity: 1; }
.lb-strip img { width: 100%; height: 100%; object-fit: cover; display: block; }

@media (max-width: 700px) {
  .lb-nav { top: auto; bottom: 0; translate: none; width: 52px; height: 52px; }
  .lb-stage { padding: 0 .5rem; }
  .lb-prev, .lb-next { position: static; }
  .lightbox[open] { grid-template-rows: auto minmax(0, 1fr) auto auto auto; }
  .lb-bottom { order: 3; }
  .lightbox .lb-prev, .lightbox .lb-next { display: none; }   /* na telefonie: przesunięcie palcem + miniatury */
  .lb-strip button { width: 60px; height: 46px; }
}
@media (prefers-reduced-motion: reduce) {
  .lightbox[open], .lb-img, .lb-spinner { animation: none !important; transition: none !important; }
  .lightbox.is-loading .lb-img { transform: none; filter: none; }
}

.site-footer .brand--footer { display: inline-block; margin-bottom: 1.25rem; }
.site-footer .brand--footer .brand-logo { height: 72px; }

/* =========================================================================
   Formularz: załączniki
   ========================================================================= */
.field .label { font-weight: 700; font-size: .95rem; }
.optional { font-weight: 500; color: var(--ink-soft); }
.upload {
  position: relative; display: grid; justify-items: center; gap: .4rem; text-align: center; padding: 1.4rem 1rem;
  border: 2px dashed #b9a98d; border-radius: 14px; background: var(--paper); transition: border-color .2s ease, background-color .2s ease;
}
.upload svg { width: 34px; height: 34px; color: var(--oak-text); }
.upload.is-over { border-color: var(--spruce-800); background: #f0eadc; }
.upload.has-error { border-color: #a23b2a; }
.upload:focus-within { border-color: var(--spruce-800); box-shadow: 0 0 0 4px rgba(36, 68, 58, .18); }
.upload-title { margin: 0; font-weight: 600; }
.upload-pick { color: var(--spruce-800); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; font-weight: 700; }
.upload-input { width: 100%; max-width: 360px; font-size: .9rem; color: var(--ink-soft); }
.upload-input::file-selector-button { min-height: 44px; margin-right: .75rem; padding: .5rem 1rem; border-radius: 999px; border: 1.5px solid var(--spruce-900); background: var(--white); color: var(--spruce-900); font-weight: 700; cursor: pointer; }
.js .upload-input { position: absolute; inset: 0; width: 100%; max-width: none; opacity: 0; cursor: pointer; }   /* cała strefa klikalna, natywne pole dalej obsługuje klawiaturę */
.upload-drop { display: none; }
.js .upload-drop { display: inline; }
.upload-list { list-style: none; margin: .75rem 0 0; padding: 0; display: grid; gap: .5rem; }
.upload-list li { display: flex; align-items: center; gap: .8rem; padding: .5rem .6rem; background: var(--white); border: 1px solid var(--line); border-radius: 12px; }
.upload-thumb { width: 48px; height: 48px; flex: none; border-radius: 8px; overflow: hidden; display: grid; place-items: center; font-size: .7rem; font-weight: 800; letter-spacing: .05em; color: var(--white); background: var(--spruce-700); }
.upload-thumb img { width: 100%; height: 100%; object-fit: cover; }
.upload-thumb--pdf { background: #a23b2a; }
.upload-thumb--zip { background: var(--oak-text); }
.upload-meta { display: grid; min-width: 0; flex: 1; line-height: 1.3; }
.upload-meta strong { font-weight: 600; font-size: .95rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.upload-meta small { color: var(--ink-soft); }
.upload-remove { width: 44px; height: 44px; flex: none; border-radius: 50%; border: 1px solid var(--line); background: var(--paper); font-size: 1.5rem; line-height: 1; cursor: pointer; color: var(--ink); }
.upload-remove:hover { background: #f7e1dc; border-color: #a23b2a; color: #7a2516; }
.upload-summary { margin: .4rem 0 0; }
.send-row { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.25rem; }
.draft-note { margin: 0; }
.link-btn { background: none; border: 0; padding: .4rem .2rem; min-height: 32px; color: var(--spruce-800); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; font: inherit; font-weight: 700; }
.upload-progress-bar { height: 12px; border-radius: 999px; background: var(--cream); overflow: hidden; border: 1px solid var(--line); }
.upload-progress-bar span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--spruce-800), var(--moss)); transition: width .2s ease; }
.upload-progress p { margin: .4rem 0 0; }
[aria-invalid="true"] { border-color: #a23b2a !important; }

/* =========================================================================
   NAGŁÓWEK v2 — dwa poziomy: pasek informacyjny + przyklejony pasek logo/menu.
   Menu nigdy nie nachodzi na logo: siatka 3 kolumn, pozycje bez łamania wierszy,
   przełączenie na menu mobilne poniżej 1180 px.
   ========================================================================= */
.topbar { background: var(--spruce-900); color: #e4ddcf; font-size: .9rem; }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 42px; }
.topbar p { margin: 0; display: flex; align-items: center; gap: .6rem; min-width: 0; }
.topbar-info { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar-info strong { color: var(--white); font-weight: 700; }
.topbar-sep { color: var(--moss); }
.topbar-links { gap: 1.25rem; flex: none; }
.topbar a { color: var(--cream); text-decoration: none; display: inline-flex; align-items: center; gap: .45rem; min-height: 42px; font-weight: 600; }
.topbar a:hover { color: var(--white); text-decoration: underline; text-underline-offset: 3px; }
.topbar svg { width: 16px; height: 16px; color: var(--moss); }
.topbar-cta { color: var(--white) !important; }
.topbar :focus-visible { outline-color: var(--moss); }
@media (max-width: 759px) { .topbar { display: none; } }
@media (max-width: 999px) { .topbar-info span:not(.topbar-sep) { display: none; } .topbar-sep { display: none; } }

.site-header .header-inner { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 1.5rem; min-height: 76px; }
.brand { display: inline-flex; align-items: center; }
.brand-logo { height: 52px; width: auto; display: block; }
.header-tools { display: flex; align-items: center; gap: .5rem; justify-self: end; }
.header-call {
  width: 48px; height: 48px; border-radius: 12px; display: grid; place-items: center;
  background: var(--spruce-900); color: var(--white); text-decoration: none;
}
.header-call svg { width: 20px; height: 20px; }
.header-cta { display: none !important; }        /* telefon jest teraz w pasku informacyjnym */
.nav-mobile-only { display: none; }
.site-nav.is-open .nav-mobile-only { display: block; }
.site-nav.is-open .nav-mobile-only a { font-weight: 800; color: var(--spruce-800); }

@media (min-width: 1180px) {
  .nav-toggle, .header-call { display: none; }
  .site-nav, .site-nav.is-open { display: block; position: static; box-shadow: none; border: 0; padding: 0; background: none; max-height: none; justify-self: end; }
  .site-nav ul { display: flex; flex-wrap: nowrap; gap: clamp(1rem, 1.8vw, 1.9rem); }
  .site-nav.is-open li { border: 0; }
  .site-nav a, .site-nav.is-open a { display: inline-block; padding: .5rem 0; font-size: 1rem; white-space: nowrap; position: relative; }
  .site-nav.is-open .nav-mobile-only { display: none; }
}
/* 1080–1179 px: menu mobilne (wcześniejszy próg 1080 px był za ciasny dla 7 pozycji) */
@media (min-width: 1080px) and (max-width: 1179px) {
  .nav-toggle { display: inline-flex; }
  .site-nav { display: none; }
  .site-nav.is-open {
    display: block; position: absolute; inset: 100% 0 auto 0; background: var(--paper); border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-lg); padding: .5rem var(--gutter) 1.5rem;
  }
  .site-nav.is-open ul { display: block; }
  .site-nav.is-open li { border-bottom: 1px solid var(--line); }
  .site-nav.is-open a { display: block; padding: 1rem .25rem; font-size: 1.1rem; }
  .site-nav.is-open a::after { display: none; }
  .mobile-call { display: flex; }
}
.site-header { position: sticky; }
.site-nav.is-open { inset: 100% 0 auto 0; }
.site-footer .brand--footer { display: inline-block; margin-bottom: 1.25rem; }
.site-footer .brand--footer .brand-logo { height: 72px; }
