/* =========================================================
   PAN TRAWNIK — premium editorial · Brzesko
   Paleta: leśna zieleń / szałwia / kość słoniowa
   ========================================================= */

:root {
  --forest: #1B4332;
  --forest-dark: #143528;
  --sage: #588157;
  --sage-soft: #6b9b6a;
  --ivory: #F8F8F6;
  --stone: #EFEFE7;
  --ink: #141414;
  --ink-soft: #4a4a45;
  --line: rgba(20, 20, 20, 0.10);
  --radius: 18px;

  --serif: "Playfair Display", Georgia, serif;
  --sans: "Inter", system-ui, sans-serif;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --shell: min(1560px, 90vw);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--sans);
  /* (1) ciepły papierowy gradient zamiast płaskiej bieli */
  background:
    radial-gradient(1200px 800px at 82% 8%, rgba(88,129,87,0.06), transparent 60%),
    radial-gradient(1000px 700px at 12% 92%, rgba(27,67,50,0.05), transparent 60%),
    linear-gradient(180deg, #FAFAF8 0%, var(--ivory) 40%, var(--stone) 100%);
  background-attachment: fixed;
  color: var(--ink);
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  position: relative;
}

/* (4) miękkie rozmyte plamy zieleni — bardzo blade, warstwa pod treścią */
body::before {
  content: "";
  position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background:
    radial-gradient(340px 340px at 15% 20%, rgba(88,129,87,0.10), transparent 70%),
    radial-gradient(420px 420px at 88% 55%, rgba(27,67,50,0.07), transparent 70%),
    radial-gradient(300px 300px at 40% 88%, rgba(88,129,87,0.06), transparent 70%);
  filter: blur(8px);
}

/* (3) botaniczny znak wodny — subtelna sylwetka liścia, ton w ton, prawy dół */
body::after {
  content: "";
  position: fixed; right: -60px; bottom: -40px; z-index: -1; pointer-events: none;
  width: 380px; height: 380px; opacity: 0.05;
  background: no-repeat center / contain
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Cpath fill='%231B4332' d='M50 4C30 24 18 44 18 64c0 18 14 32 32 32s32-14 32-32C82 44 70 24 50 4zm0 12c14 16 22 32 22 48a22 22 0 0 1-20 22V40a2 2 0 0 0-4 0v46a22 22 0 0 1-20-22c0-16 8-32 22-48z'/%3E%3C/svg%3E");
}

h1, h2, h3 { font-family: var(--serif); font-weight: 400; line-height: 1.05; letter-spacing: -0.02em; }

img { display: block; max-width: 100%; }

a { color: inherit; text-decoration: none; }

::selection { background: var(--sage); color: #fff; }

.kicker {
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--sage);
  margin-bottom: 1.4rem;
  display: inline-block;
}
.kicker--light { color: rgba(255,255,255,0.85); }

/* ============ REVEAL BASE ============ */
/* Hidden states are gated behind .js-anim (added by JS). Without JS everything
   is visible immediately — no blank sections if the script fails to load. */
.js-anim .reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); }
.js-anim .reveal.in { opacity: 1; transform: none; }

/* image reveal — a sliding mask (::after) does the clip so the OUTER observed
   box keeps full size (clip-path on the observed element itself collapses its
   intersection box to 0 → observer never fires → deadlock).
   Graceful degradation: images are VISIBLE by default. JS adds `.js-anim` to
   arm the animation; if JS never runs, images simply show without motion. */
.reveal-img { position: relative; overflow: hidden; }
.reveal-img img { transition: transform 1.4s var(--ease); }
.js-anim .reveal-img::after {
  content: ""; position: absolute; inset: 0; z-index: 3;
  background: var(--ivory); transform-origin: bottom;
  transform: scaleY(1); transition: transform 1.1s var(--ease);
}
.js-anim .reveal-img img { transform: scale(1.14); }
.js-anim .reveal-img.in::after { transform: scaleY(0); }
.js-anim .reveal-img.in img { transform: scale(1); }

.reveal-line { display: block; overflow: hidden; }
.js-anim .reveal-line > span { display: block; transform: translateY(105%); transition: transform 1s var(--ease); }
.js-anim .reveal-line.in > span { transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal, .reveal-img { opacity: 1 !important; transform: none !important; clip-path: none !important; }
  .reveal-line > span { transform: none !important; }
  html { scroll-behavior: auto; }
}

/* ============ BUTTONS ============ */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--sans);
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  padding: 1.05rem 1.9rem;
  border-radius: 100px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform 0.5s var(--ease), background 0.4s var(--ease), color 0.4s var(--ease), box-shadow 0.5s var(--ease);
  will-change: transform;
}
.btn--primary { background: var(--forest); color: var(--ivory); box-shadow: 0 12px 30px -12px rgba(27,67,50,0.55); }
.btn--primary:hover { background: var(--sage); box-shadow: 0 18px 40px -14px rgba(88,129,87,0.6); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--forest); color: var(--forest); }
.btn--big { padding: 1.25rem 2.6rem; font-size: 1rem; }

/* ============ NAV ============ */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 1.35rem 0;
  transition: background 0.5s var(--ease), padding 0.5s var(--ease), box-shadow 0.5s var(--ease);
}
.nav.scrolled {
  background: rgba(248,248,246,0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  padding: 0.85rem 0;
  box-shadow: 0 1px 0 var(--line);
}
.nav__inner { width: var(--shell); margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 2rem; }
.nav__logo { display: flex; align-items: center; gap: 0.65rem; font-family: var(--serif); font-size: 1.28rem; color: var(--forest); letter-spacing: -0.02em; }
.nav__logo-mark { width: 12px; height: 12px; border-radius: 50%; background: var(--sage); flex: none; box-shadow: 0 0 0 4px rgba(88,129,87,0.2); }
.nav__links { display: flex; gap: 2.1rem; }
.nav__links a { font-size: 0.9rem; font-weight: 500; color: var(--ink-soft); position: relative; padding: 0.2rem 0; transition: color 0.3s; }
.nav__links a::after { content: ""; position: absolute; left: 0; bottom: -2px; width: 0; height: 1px; background: var(--forest); transition: width 0.4s var(--ease); }
.nav__links a:hover { color: var(--forest); }
.nav__links a:hover::after { width: 100%; }
.nav__cta { display: inline-flex; align-items: center; gap: 0.5rem; background: var(--forest); color: var(--ivory); font-weight: 600; font-size: 0.88rem; padding: 0.7rem 1.3rem; border-radius: 100px; transition: transform 0.5s var(--ease), background 0.4s; will-change: transform; }
.nav__cta:hover { background: var(--sage); }
.nav__burger { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav__burger span { width: 26px; height: 2px; background: var(--forest); transition: transform 0.4s var(--ease), opacity 0.3s; }
.nav__burger.open span:first-child { transform: translateY(3.5px) rotate(45deg); }
.nav__burger.open span:last-child { transform: translateY(-3.5px) rotate(-45deg); }

/* ============ HERO ============ */
.hero { position: relative; min-height: 100svh; display: flex; align-items: center; overflow: hidden; padding: 7rem 0 4rem; }
.hero__media { position: absolute; inset: 0; z-index: 0; }
.hero__img { width: 100%; height: 120%; object-fit: cover; will-change: transform; }
.hero__scrim {
  position: absolute; inset: 0;
  background:
    linear-gradient(to top, rgba(19,53,40,0.85) 0%, rgba(19,53,40,0.25) 45%, rgba(19,53,40,0.35) 100%);
}
.hero__content { position: relative; z-index: 2; width: var(--shell); margin: 0 auto; color: var(--ivory); }
.hero__kicker { font-size: 0.78rem; font-weight: 600; letter-spacing: 0.22em; text-transform: uppercase; color: rgba(255,255,255,0.82); margin-bottom: 1.6rem; }
.hero__title { font-size: clamp(2.9rem, 7vw, 5.4rem); font-weight: 400; margin-bottom: 1.6rem; }
.hero__sub { max-width: 40ch; font-size: clamp(1rem, 1.5vw, 1.22rem); color: rgba(255,255,255,0.9); font-weight: 300; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 2.4rem; }
.hero__actions .btn--ghost { color: var(--ivory); border-color: rgba(255,255,255,0.35); }
.hero__actions .btn--ghost:hover { background: rgba(255,255,255,0.08); border-color: #fff; color: #fff; }
.hero__scroll { position: absolute; bottom: 2.2rem; right: max(4vw, calc((100vw - var(--shell)) / 2)); z-index: 2; display: flex; flex-direction: column; align-items: center; gap: 0.7rem; color: rgba(255,255,255,0.7); }
.hero__scroll-line { width: 1px; height: 46px; background: rgba(255,255,255,0.4); position: relative; overflow: hidden; }
.hero__scroll-line::after { content: ""; position: absolute; top: -100%; left: 0; width: 100%; height: 100%; background: #fff; animation: scrolldot 2.2s var(--ease) infinite; }
@keyframes scrolldot { 0% { top: -100%; } 60%,100% { top: 100%; } }
.hero__scroll-text { font-size: 0.65rem; letter-spacing: 0.2em; text-transform: uppercase; writing-mode: vertical-rl; }

/* ============ MARQUEE ============ */
.marquee { background: var(--forest); color: var(--ivory); padding: 1.15rem 0; overflow: hidden; white-space: nowrap; }
.marquee__track { display: inline-flex; align-items: center; gap: 1.6rem; animation: marquee 32s linear infinite; }
.marquee__track span { font-family: var(--serif); font-size: 1.35rem; font-weight: 400; letter-spacing: 0.01em; }
.marquee__track i { color: var(--sage-soft); font-style: normal; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ============ SECTION SHELL ============ */
.about, .services, .pricing, .process, .gallery { width: var(--shell); margin: 0 auto; }
.about { padding: clamp(3.5rem, 6vw, 6rem) 0; }
.services { padding: clamp(3rem, 5vw, 4.5rem) 0; }
.pricing__inner { padding: 0; }
.pricing { background: var(--stone); width: 100%; }
.pricing__inner { width: var(--shell); margin: 0 auto; padding: clamp(3.5rem, 6vw, 6rem) 0; }
.process { padding: clamp(3rem, 5vw, 5rem) 0; }
.gallery { padding: clamp(3rem, 5vw, 4.5rem) 0 clamp(3.5rem, 6vw, 6rem); }

/* ============ ABOUT ============ */
.about__grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2.5rem, 5vw, 5rem); align-items: center; }
.about__media { border-radius: var(--radius); overflow: hidden; height: clamp(340px, 42vh, 520px); }
.about__media img { width: 100%; height: 100%; object-fit: cover; }
.about__text h2 { font-size: clamp(1.8rem, 3vw, 2.6rem); margin-bottom: 1.3rem; max-width: 16ch; }
.about__text p { color: var(--ink-soft); margin-bottom: 1.1rem; max-width: 46ch; }
.about__text strong { color: var(--ink); font-weight: 600; }
.about__points { list-style: none; margin-top: 2rem; display: grid; grid-template-columns: 1fr 1fr; gap: 0.9rem 1.5rem; }
.about__points li { display: flex; align-items: center; gap: 0.7rem; font-size: 0.95rem; font-weight: 500; }
.about__points span { width: 7px; height: 7px; border-radius: 50%; background: var(--sage); flex: none; }

/* ============ SERVICES ============ */
.services__head { max-width: 620px; margin-bottom: 2.4rem; }
.services__head h2 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); margin-bottom: 1.1rem; }
.services__intro { color: var(--ink-soft); }
.services__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.6rem; }
.service { position: relative; border-radius: var(--radius); overflow: hidden; background: var(--stone); min-height: 320px; display: flex; align-items: flex-end; transform: translateZ(0); transition: transform 0.6s var(--ease), box-shadow 0.6s var(--ease); }
.service--wide { grid-column: 1 / -1; min-height: 300px; }
.service__img { position: absolute; inset: 0; }
.service__img img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.1s var(--ease); }
.service::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(19,53,40,0.9) 0%, rgba(19,53,40,0.15) 55%, transparent 100%); transition: opacity 0.5s; }
.service__body { position: relative; z-index: 2; padding: 2.2rem; color: var(--ivory); }
.service__num { font-family: var(--serif); font-size: 0.85rem; letter-spacing: 0.1em; color: var(--sage-soft); display: block; margin-bottom: 0.6rem; }
.service__body h3 { font-size: 1.6rem; margin-bottom: 0.5rem; }
.service__body p { font-size: 0.95rem; color: rgba(255,255,255,0.85); max-width: 40ch; font-weight: 300; }
.service:hover { transform: translateY(-6px); box-shadow: 0 30px 60px -30px rgba(19,53,40,0.5); }
.service:hover .service__img img { transform: scale(1.07); }

/* ============ PRICING ============ */
.pricing__head { max-width: 640px; margin-bottom: 2.2rem; }
.pricing__head h2 { font-size: clamp(1.8rem, 3.2vw, 2.7rem); margin-bottom: 1rem; }
.pricing__head p { color: var(--ink-soft); }
.pricing__list { border-top: 1px solid var(--line); }
.price { display: flex; align-items: baseline; gap: 1rem; padding: 1.5rem 0; border-bottom: 1px solid var(--line); }
.price__name { font-family: var(--serif); font-size: clamp(1.15rem, 2.2vw, 1.55rem); color: var(--ink); flex: none; }
.price__dots { flex: 1; border-bottom: 1px dotted rgba(20,20,20,0.25); transform: translateY(-4px); }
.price__val { font-family: var(--sans); font-weight: 600; font-size: 1.05rem; color: var(--forest); flex: none; display: flex; flex-direction: column; align-items: flex-end; }
.price__val small { font-weight: 400; font-size: 0.72rem; color: var(--ink-soft); letter-spacing: 0.02em; }
.price--accent .price__val { font-size: 1.5rem; color: var(--sage); }
.pricing__note { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem; margin-top: 3rem; padding: 2rem; background: var(--forest); border-radius: var(--radius); color: var(--ivory); }
.pricing__badge { display: flex; flex-direction: column; gap: 0.3rem; }
.pricing__badge strong { font-size: 1.25rem; font-family: var(--serif); font-weight: 500; }
.pricing__badge span { font-size: 0.9rem; color: rgba(255,255,255,0.75); }

/* ============ PROCESS ============ */
.process__head { max-width: 620px; margin-bottom: 2.4rem; }
.process__head h2 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); }
.process__steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2.5rem; }
.step { position: relative; padding-top: 2.5rem; border-top: 2px solid var(--forest); }
.step__num { font-family: var(--serif); font-size: 2.6rem; color: var(--sage); display: block; margin-bottom: 1rem; line-height: 1; }
.step h3 { font-size: 1.35rem; margin-bottom: 0.6rem; }
.step p { font-size: 0.92rem; color: var(--ink-soft); }

/* ============ GALLERY ============ */
.gallery__head { max-width: 620px; margin-bottom: 2.2rem; }
.gallery__head h2 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); }
.gallery__grid { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 260px; gap: 1.2rem; }
.gallery__item { border-radius: var(--radius); overflow: hidden; }
.gallery__item--tall { grid-row: span 2; }
.gallery__item img { width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease); }
.gallery__item:hover img { transform: scale(1.06); }
.gallery__note { text-align: center; margin-top: 2rem; font-size: 0.85rem; color: var(--ink-soft); font-style: italic; }

/* ============ CONTACT ============ */
.contact { position: relative; overflow: hidden; padding: clamp(4rem, 7vw, 6.5rem) 0; }
.contact__media { position: absolute; inset: 0; z-index: 0; }
.contact__media img { width: 100%; height: 120%; object-fit: cover; will-change: transform; }
.contact__scrim { position: absolute; inset: 0; background: linear-gradient(to right, rgba(19,53,40,0.94) 0%, rgba(19,53,40,0.78) 55%, rgba(19,53,40,0.6) 100%); }
.contact__inner { position: relative; z-index: 2; width: var(--shell); margin: 0 auto; color: var(--ivory); }
.contact__title { font-size: clamp(2.2rem, 4.5vw, 3.6rem); font-weight: 400; margin-bottom: 1.2rem; }
.contact__sub { font-size: clamp(1rem, 1.6vw, 1.2rem); color: rgba(255,255,255,0.85); max-width: 44ch; font-weight: 300; }
.contact__cards { display: flex; flex-wrap: wrap; gap: 1rem; margin: 2.8rem 0; }
.ccard { display: flex; flex-direction: column; gap: 0.4rem; padding: 1.4rem 1.7rem; background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.16); border-radius: 14px; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); min-width: 200px; transition: transform 0.5s var(--ease), background 0.4s; will-change: transform; }
a.ccard:hover { background: rgba(255,255,255,0.15); }
.ccard__label { font-size: 0.7rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--sage-soft); font-weight: 600; }
.ccard__val { font-size: 1.15rem; font-weight: 500; }

/* ============ FOOTER ============ */
.footer { background: var(--forest-dark); color: var(--ivory); padding: clamp(3rem, 5vw, 4rem) 0 2.5rem; }
.footer__inner { width: var(--shell); margin: 0 auto; display: grid; gap: 2rem; text-align: center; justify-items: center; }
.footer__brand { display: flex; align-items: center; gap: 0.6rem; font-family: var(--serif); font-size: 1.5rem; }
.footer__tag { font-family: var(--serif); font-size: 1.15rem; font-weight: 400; color: rgba(255,255,255,0.7); font-style: italic; }
.footer__nav { display: flex; gap: 2rem; flex-wrap: wrap; justify-content: center; }
.footer__nav a { font-size: 0.9rem; color: rgba(255,255,255,0.75); transition: color 0.3s; }
.footer__nav a:hover { color: var(--sage-soft); }
.footer__meta { display: flex; flex-direction: column; gap: 0.35rem; font-size: 0.82rem; color: rgba(255,255,255,0.5); margin-top: 1rem; padding-top: 2rem; border-top: 1px solid rgba(255,255,255,0.12); width: 100%; }

/* ============ FAB ============ */
.fab { position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 90; width: 56px; height: 56px; border-radius: 50%; background: var(--forest); color: var(--ivory); display: none; align-items: center; justify-content: center; box-shadow: 0 12px 30px -8px rgba(19,53,40,0.6); transition: transform 0.4s var(--ease), background 0.3s; }
.fab:hover { background: var(--sage); transform: scale(1.06); }

/* ============ RESPONSIVE ============ */
@media (max-width: 940px) {
  .nav__links, .nav__cta { display: none; }
  .nav__burger { display: flex; }
  .nav__links.mobile-open {
    display: flex; flex-direction: column; position: fixed; inset: 0; top: 0;
    background: var(--ivory); padding: 6rem 2rem 2rem; gap: 1.5rem; z-index: 99;
  }
  .nav__links.mobile-open a { font-size: 1.5rem; font-family: var(--serif); color: var(--forest); }
  .about__grid { grid-template-columns: 1fr; }
  .about__media { aspect-ratio: 16/11; max-height: 460px; }
  .services__grid { grid-template-columns: 1fr; }
  .process__steps { grid-template-columns: 1fr 1fr; gap: 2rem 1.5rem; }
  .gallery__grid { grid-template-columns: 1fr 1fr; grid-auto-rows: 200px; }
  .fab { display: flex; }
}
@media (max-width: 560px) {
  :root { --shell: 90vw; }
  .hero__actions { flex-direction: column; align-items: stretch; }
  .hero__actions .btn { width: 100%; }
  .about__points { grid-template-columns: 1fr; }
  .process__steps { grid-template-columns: 1fr; }
  .gallery__grid { grid-template-columns: 1fr; grid-auto-rows: 240px; }
  .gallery__item--tall { grid-row: span 1; }
  .pricing__note { flex-direction: column; align-items: stretch; text-align: center; }
  .pricing__note .btn { width: 100%; }
  .price__name { font-size: 1.1rem; }
  .hero__scroll { display: none; }
}
