/* ==========================================================================
   Harce — page layout (landing + portfolio). Built on base.css tokens.
   ========================================================================== */

/* ── HEADER ─────────────────────────────────────────────────────────────── */
.header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  display: flex; align-items: center; gap: var(--pad);
  padding: 18px var(--pad);
  transition: background .3s ease, box-shadow .3s ease, color .3s ease;
  color: #fff; /* over-photo default */
}
.header .brand { margin-right: auto; display: flex; align-items: center; }
.header .brand img { height: clamp(52px, 5vw, 66px); width: auto; display: block; }
.header .brand .logo-dark { display: block; }  /* cream, over photo */
.header .brand .logo-light { display: none; }   /* ink, when scrolled */

.header .nav { display: flex; align-items: center; gap: clamp(18px, 2.4vw, 34px); }
.header .nav .navlink { color: #fff; opacity: .92; text-shadow: 0 1px 8px rgba(0,0,0,.25); }
.header .nav .navlink:hover { opacity: 1; }

/* scrolled / on light pages */
.header.solid {
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 1px 0 var(--line-soft);
  color: var(--ink);
}
.header.solid .brand .logo-dark { display: none; }
.header.solid .brand .logo-light { display: block; }
.header.solid .nav .navlink { color: var(--ink); text-shadow: none; }
.header.solid .btn-on-photo { border-color: var(--ink); color: var(--ink); }
.header.solid .btn-on-photo:hover { background: var(--ink); color: var(--cream); }

.nav-toggle { display: none; }

/* ── FULL-SCREEN HERO ───────────────────────────────────────────────────── */
.hero {
  position: relative;
  height: 100svh; min-height: 560px;
  overflow: hidden;
}
.hero-slides { position: absolute; inset: 0; z-index: 0; background: #2a2621; }
.hero-slide {
  position: absolute; inset: 0; opacity: 0;
  transition: opacity 1.6s ease; z-index: 1;
}
.hero-slide.active { opacity: 1; z-index: 2; }
.hero-slide img { width: 100%; height: 100%; object-fit: cover; }
.hero-slide.active img { animation: heroZoom 8s ease-out both; }
@keyframes heroZoom { from { transform: scale(1.06); } to { transform: scale(1); } }

/* soft scrims: top for the header, bottom for the CTA bar */
.hero::before, .hero::after {
  content: ""; position: absolute; left: 0; right: 0; z-index: 3; pointer-events: none;
}
.hero::before { top: 0; height: 220px; background: linear-gradient(to bottom, rgba(30,26,22,.42), transparent); }
.hero::after  { bottom: 0; height: 240px; background: linear-gradient(to top, rgba(30,26,22,.46), transparent); }

.hero-bar {
  position: absolute; z-index: 4; left: 0; right: 0; bottom: 0;
  display: flex; align-items: flex-end; justify-content: space-between; gap: 24px;
  padding: var(--pad) var(--pad) clamp(28px, 4vw, 48px);
}
.hero-cta { font-size: 15px; padding: 17px 34px; }
.hero-caption {
  font-family: var(--font-head);
  text-align: right; color: #fff;
  font-size: clamp(12px, 1.4vw, 14px); letter-spacing: .16em; text-transform: uppercase;
  text-shadow: 0 1px 10px rgba(0,0,0,.35);
  line-height: 1.9;
}
.hero-caption .sep { opacity: .5; margin: 0 .5em; }

/* small down-hint */
.hero-scroll {
  position: absolute; z-index: 4; left: 50%; bottom: 18px; transform: translateX(-50%);
  color: #fff; opacity: .7; font-size: 20px;
}

/* ── SECTION SCAFFOLD ───────────────────────────────────────────────────── */
.two-col {
  display: grid;
  /* label / photo column + a readable text column — grouped left, not stretched
     across the full page width */
  grid-template-columns: minmax(190px, 280px) minmax(0, 62ch);
  justify-content: start;
  gap: clamp(32px, 5vw, 76px); align-items: start;
}
.section-head { margin-bottom: clamp(28px, 4vw, 52px); }
.section-head .kicker { display: block; margin-bottom: 14px; }
.lead {
  font-size: clamp(21px, 2.2vw, 26px); line-height: 1.5;
  margin: 0 0 1em; color: var(--ink);
}
.prose p { max-width: 60ch; }
.prose p:last-child { margin-bottom: 0; }
/* fill the whole column, so the text lines up with the right margin
   (and, in O mnie, with the photo) instead of stopping mid-column */
.prose-fill p { max-width: none; }
.pull {
  font-style: italic; color: var(--muted);
  border-left: 2px solid var(--line); padding-left: 22px; margin: 0;
  max-width: 60ch;
}

/* ── OFERTA ─────────────────────────────────────────────────────────────── */
.offer {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 0; border-top: 1px solid var(--line-soft);
}
.offer-item {
  padding: 34px 32px 38px;
  border-bottom: 1px solid var(--line-soft);
  border-right: 1px solid var(--line-soft);
}
.offer-item:nth-child(3n) { border-right: 0; }
.offer-item .big {
  font-family: var(--font-head);
  font-size: clamp(30px, 3.4vw, 40px); line-height: 1; color: var(--ink);
  margin-bottom: 16px;
}
.offer-item p { margin: 0; color: var(--muted); font-size: 17px; line-height: 1.55; }

/* ── REPORTAGE CAROUSEL — full-bleed band between "Jak pracuję" and "Oferta" ─ */
.reel-section { padding-block: 0 clamp(48px, 6vw, 96px); }
.reel { position: relative; }
.reel-full { width: 100%; }
.reel-track {
  display: flex; gap: 0;
  overflow-x: auto; scroll-snap-type: x mandatory;
  scrollbar-width: none; -ms-overflow-style: none;
}
.reel-track::-webkit-scrollbar { display: none; }
.reel-slide { flex: 0 0 100%; scroll-snap-align: center; }
.reel-slide img {
  width: 100%; height: min(56.25vw, 82vh); object-fit: cover; display: block;
}
.reel-nav {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 3;
  width: 46px; height: 46px; border-radius: 50%;
  border: 0; cursor: pointer;
  background: rgba(47,42,37,.42); color: #fff; font-size: 22px; line-height: 1;
  display: grid; place-items: center;
  transition: background .2s ease;
}
.reel-nav:hover { background: rgba(47,42,37,.7); }
.reel-nav.prev { left: 14px; }
.reel-nav.next { right: 14px; }
.reel-dots { display: flex; justify-content: center; gap: 9px; margin-top: 18px; }
.reel-dot {
  width: 8px; height: 8px; border-radius: 50%; padding: 0; cursor: pointer;
  border: 1px solid var(--muted); background: transparent;
  transition: background .2s ease, transform .2s ease;
}
.reel-dot.active { background: var(--ink); border-color: var(--ink); transform: scale(1.15); }

/* ── O MNIE ─────────────────────────────────────────────────────────────── */
.portrait img { width: 100%; aspect-ratio: 4/5; object-fit: cover; border-radius: var(--radius); }
.portrait figcaption { font-family: var(--font-head); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-top: 12px; }
.about .harce-eq { color: var(--muted); }

/* ── KONTAKT ────────────────────────────────────────────────────────────── */
.contact-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(32px, 6vw, 80px); align-items: start; }
.contact-list { list-style: none; margin: 22px 0 0; padding: 0; display: grid; gap: 12px; font-size: 18px; }
.contact-list a { color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--line); padding-bottom: 1px; }
.contact-list a:hover { border-color: var(--ink); }
.contact-list .addr { color: var(--muted); }

.form { display: grid; gap: 18px; }
.form .row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field label { display: block; font-family: var(--font-head); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 7px; }
.input {
  width: 100%; font: inherit; font-size: 17px; color: var(--ink);
  background: transparent; border: 0; border-bottom: 1px solid var(--line);
  padding: 8px 2px; border-radius: 0;
}
.input:focus-visible { outline: none; border-color: var(--ink); }
textarea.input { min-height: 96px; resize: vertical; }
.form .btn { justify-self: start; margin-top: 6px; }
.confirmation {
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px 26px; color: var(--ink); font-size: 19px;
}

/* ── FOOTER ─────────────────────────────────────────────────────────────── */
.footer { background: var(--dark); color: var(--cream); padding-block: clamp(40px, 5vw, 64px); }
.footer .inner { display: flex; flex-wrap: wrap; gap: 26px; align-items: center; justify-content: space-between; }
.footer img { height: 46px; width: auto; }
.footer .cols { display: flex; gap: 26px; flex-wrap: wrap; font-family: var(--font-head); font-size: 14px; letter-spacing: .04em; }
.footer a { color: var(--muted-dark); text-decoration: none; }
.footer a:hover { color: var(--cream); }
.footer .fine { color: var(--muted-dark); font-family: var(--font-head); font-size: 12px; letter-spacing: .08em; width: 100%; text-align: right; }

/* ══ PORTFOLIO PAGE ══════════════════════════════════════════════════════ */
.subpage { padding-top: 92px; } /* clear the fixed header (solid on subpages) */
.page-head { padding-block: clamp(40px, 6vw, 80px) clamp(24px, 3vw, 40px); }
.page-head .kicker { display: block; margin-bottom: 14px; }
.page-head p { color: var(--muted); max-width: 56ch; margin: 8px 0 0; }

.gallery { columns: 3; column-gap: 14px; padding-bottom: clamp(48px, 7vw, 100px); }
.gallery figure { break-inside: avoid; margin: 0 0 14px; }
.gallery img {
  width: 100%; height: auto; border-radius: var(--radius);
  cursor: zoom-in; transition: opacity .2s ease;
}
.gallery img:hover { opacity: .9; }

/* — lightbox — */
.lightbox {
  position: fixed; inset: 0; z-index: 200; display: none;
  align-items: center; justify-content: center;
  background: rgba(24,21,18,.94); padding: clamp(16px, 4vw, 56px);
}
.lightbox.open { display: flex; }
.lightbox img {
  max-width: 100%; max-height: 100%; width: auto; height: auto;
  border-radius: var(--radius); box-shadow: 0 20px 60px rgba(0,0,0,.5);
}
.lightbox-btn {
  position: absolute; z-index: 2; border: 0; cursor: pointer;
  background: rgba(242,237,228,.12); color: #fff;
  width: 52px; height: 52px; border-radius: 50%;
  font-size: 26px; line-height: 1; display: grid; place-items: center;
  transition: background .2s ease;
}
.lightbox-btn:hover { background: rgba(242,237,228,.26); }
.lightbox-close { top: 20px; right: 20px; }
.lightbox-prev { left: clamp(10px, 3vw, 34px); top: 50%; transform: translateY(-50%); }
.lightbox-next { right: clamp(10px, 3vw, 34px); top: 50%; transform: translateY(-50%); }
.lightbox-counter {
  position: absolute; bottom: 22px; left: 0; right: 0; text-align: center;
  color: rgba(242,237,228,.75); font-family: var(--font-head);
  font-size: 13px; letter-spacing: .1em;
}

/* ══ RESPONSIVE ══════════════════════════════════════════════════════════ */
@media (min-width: 1500px) { .gallery { columns: 4; } }
@media (max-width: 1000px) { .gallery { columns: 2; } }

@media (max-width: 860px) {
  body { font-size: 18px; }
  .two-col, .contact-grid { grid-template-columns: 1fr; gap: clamp(24px, 6vw, 44px); }
  .offer { grid-template-columns: 1fr; border-top: 0; }
  .offer-item { border-right: 0; border-top: 1px solid var(--line-soft); }
  .portrait { max-width: 360px; }
  .form .row-2 { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  /* The solid header's backdrop-filter creates a containing block that would
     trap the fixed full-screen overlay inside the header box (breaking the
     mobile menu on Portfolio / after scrolling). Drop the blur on mobile. */
  .header.solid { backdrop-filter: none; -webkit-backdrop-filter: none; }

  /* ── Mobile menu: full-screen overlay ──────────────────────────────── */
  .nav-toggle {
    display: inline-flex; align-items: center; justify-content: center;
    width: 44px; height: 40px; padding: 0; cursor: pointer;
    background: transparent; border: 0; color: inherit; line-height: 1;
    position: relative; z-index: 300; font-size: 0;
  }
  .nav-toggle::before { content: "\2630"; font-size: 24px; }          /* ☰ */
  .nav-toggle[aria-expanded="true"]::before { content: "\2715"; font-size: 26px; } /* ✕ */
  .nav-toggle[aria-expanded="true"] { color: var(--ink); }

  .header .nav {
    position: fixed; inset: 0; z-index: 200;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: clamp(22px, 5.2vh, 40px);
    background: var(--bg);
    opacity: 0; visibility: hidden; pointer-events: none;
    transition: opacity .32s ease, visibility .32s ease;
  }
  .header .nav.open { opacity: 1; visibility: visible; pointer-events: auto; }
  .header .nav .navlink {
    color: var(--ink); opacity: 1;
    font-family: var(--font-head);
    font-size: clamp(28px, 8vw, 42px); letter-spacing: .01em;
    text-shadow: none;
  }
  .header .nav .navlink[aria-current="page"] { text-decoration: underline; text-underline-offset: 8px; }
  .header .nav::after {
    content: "fotografia ślubna · Wrocław · Polska · Europa";
    font-family: var(--font-head); font-size: 10px; letter-spacing: .1em;
    text-transform: uppercase; color: var(--muted);
    position: absolute; bottom: 40px; left: 20px; right: 20px; text-align: center;
  }

  .hero-bar { flex-direction: column; align-items: flex-start; gap: 16px; }
  .hero-caption { text-align: left; }
  .gallery { columns: 1; }
}

/* ══ COOKIE CONSENT BANNER ═══════════════════════════════════════════════ */
.cookie-banner {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 400;
  display: flex; flex-wrap: wrap; align-items: center; gap: 14px clamp(20px, 4vw, 48px);
  padding: 18px clamp(20px, 5vw, 56px);
  background: var(--surface);
  border-top: 1px solid var(--line-soft);
  box-shadow: 0 -8px 30px rgba(47, 42, 37, .12);
}
.cookie-text {
  margin: 0; flex: 1 1 340px;
  font-size: 15px; line-height: 1.55; color: var(--ink);
}
.cookie-text a { color: var(--ink); text-underline-offset: 3px; }
.cookie-actions { display: flex; gap: 12px; flex: 0 0 auto; }
.cookie-banner .btn { padding: 12px 24px; }
@media (max-width: 560px) {
  .cookie-actions { width: 100%; }
  .cookie-actions .btn { flex: 1; }
}

/* ══ LEGAL / TEXT PAGE (Polityka prywatności) ════════════════════════════ */
.legal { max-width: 80ch; }
.legal h2 { margin: 1.7em 0 .5em; font-size: clamp(22px, 2.4vw, 28px); }
.legal h2:first-child { margin-top: 0; }
.legal h3 { margin: 1.3em 0 .4em; font-size: clamp(18px, 2vw, 21px); }
.legal p, .legal li { color: var(--ink); }
.legal ul { padding-left: 1.25em; margin: 0 0 1em; }
.legal li { margin-bottom: .45em; }
.legal a { color: var(--ink); }
.legal .updated {
  color: var(--muted); font-family: var(--font-head);
  font-size: 13px; letter-spacing: .04em; margin-bottom: 2em;
}
.legal .lead-note {
  border-left: 2px solid var(--line); padding-left: 18px;
  color: var(--muted); font-style: italic; margin: 0 0 1.6em;
}
