/* =========================================================
   cvify — Kinga Rychlik
   Paleta marki: tekst #1F2937 / tło #FDE68A (kontrast WCAG AAA)
   Projekt z naciskiem na dostępność (a11y).
   ========================================================= */

:root {
  /* Marka */
  --ink:        #1F2937;   /* tekst / sekcje ciemne */
  --ink-soft:   #374151;   /* tekst drugorzędny na jasnym */
  --yellow:     #FDE68A;   /* tło marki */
  --yellow-deep:#FACC2E;   /* akcent cieplejszy */
  --surface:    #FFFFFF;   /* karty */
  --cream:      #FFFBEB;   /* delikatne tło sekcji */
  --line:       #E7E2CF;   /* subtelne linie na jasnym */
  --line-dark:  #374151;   /* linie na ciemnym */
  --on-dark:    #F9FAFB;   /* tekst na ciemnym */
  --on-dark-soft:#D1D5DB;

  /* Promienie, cienie, ruch */
  --r-sm: 10px;
  --r-md: 18px;
  --r-lg: 28px;
  --shadow-sm: 0 2px 8px rgba(31,41,55,.08);
  --shadow-md: 0 14px 40px rgba(31,41,55,.12);
  --shadow-lg: 0 28px 70px rgba(31,41,55,.18);
  --ease: cubic-bezier(.22,.61,.36,1);

  --maxw: 1140px;
  --gap: clamp(1.25rem, 4vw, 3rem);
}

/* ---------- Reset / podstawy ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 90px; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--ink);
  background: var(--cream);
  line-height: 1.65;
  font-size: clamp(1rem, 0.6vw + 0.9rem, 1.0625rem);
  -webkit-font-smoothing: antialiased;
}

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

a { color: inherit; text-underline-offset: 3px; }

h1, h2, h3 { line-height: 1.12; letter-spacing: -0.02em; margin: 0 0 .5em; font-weight: 800; }

p { margin: 0 0 1.1em; }

/* ---------- Dostępność: fokus + skip link ---------- */
:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
  border-radius: 4px;
}
.reviews :focus-visible { outline-color: var(--yellow); }

.skip-link {
  position: fixed;
  top: -100px;
  left: 16px;
  z-index: 999;
  background: var(--ink);
  color: var(--on-dark);
  padding: .75rem 1.25rem;
  border-radius: var(--r-sm);
  font-weight: 700;
  text-decoration: none;
  transition: top .2s var(--ease);
}
.skip-link:focus { top: 16px; }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: clamp(1.1rem, 4vw, 2rem); }
.narrow { max-width: 760px; }

.section { padding-block: clamp(3.5rem, 8vw, 6.5rem); }

.eyebrow {
  text-transform: uppercase;
  letter-spacing: .18em;
  font-size: .78rem;
  font-weight: 700;
  color: var(--ink-soft);
  margin: 0 0 .9rem;
}
.eyebrow.center { text-align: center; }
.eyebrow.light { color: var(--on-dark-soft); }

.section-title { font-size: clamp(1.8rem, 4vw, 2.9rem); }
.section-title.center { text-align: center; }
.section-title.light { color: var(--on-dark); }

.section-sub {
  text-align: center;
  max-width: 620px;
  margin: -.2rem auto 2.6rem;
  color: var(--ink-soft);
}
.center { text-align: center; }

/* ---------- Przyciski ---------- */
.btn {
  --btn-bg: var(--ink);
  --btn-fg: var(--on-dark);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  min-height: 52px;             /* cel dotykowy >= 44px */
  padding: .85rem 1.6rem;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), background-color .2s var(--ease), color .2s var(--ease);
}
.btn-primary:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.btn-primary:active { transform: translateY(-1px); }

.btn-ghost {
  background: transparent;
  color: var(--ink);
}
.btn-ghost:hover { background: var(--ink); color: var(--on-dark); transform: translateY(-3px); }

.btn-block { width: 100%; }

/* ---------- Header / nawigacja ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(253, 230, 138, .85);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid rgba(31,41,55,.10);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; min-height: 70px; }

.logo {
  font-weight: 800;
  font-size: 1.6rem;
  letter-spacing: -0.04em;
  text-decoration: none;
  color: var(--ink);
}
.logo-mark { background: var(--ink); color: var(--yellow); padding: 0 .12em; border-radius: 7px; }
.logo-dot { color: var(--ink); }

.main-nav { display: flex; align-items: center; }
.nav-list {
  display: flex;
  align-items: center;
  gap: .35rem;
  list-style: none;
  margin: 0; padding: 0;
}
.nav-list a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: .45rem .85rem;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
  color: var(--ink);
  transition: background-color .18s var(--ease), color .18s var(--ease);
}
.nav-list a:not(.nav-cta):hover { background: var(--surface); }
.nav-list a:not(.nav-cta)[aria-current="true"] { background: var(--surface); }
.nav-cta {
  background: var(--ink);
  color: var(--on-dark) !important;
  margin-left: .35rem;
}
.nav-cta:hover { background: var(--ink-soft) !important; }

/* Hamburger (mobile) */
.nav-toggle {
  display: none;
  width: 46px; height: 46px;
  border: 2px solid var(--ink);
  border-radius: 12px;
  background: transparent;
  cursor: pointer;
  padding: 0;
  flex-direction: column;
  gap: 5px;
  align-items: center;
  justify-content: center;
}
.nav-toggle-bar { display: block; width: 22px; height: 2.5px; background: var(--ink); border-radius: 2px; transition: transform .25s var(--ease), opacity .2s var(--ease); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* ---------- HERO ---------- */
.hero {
  background:
    radial-gradient(1200px 600px at 85% -10%, rgba(250,204,46,.55), transparent 60%),
    radial-gradient(900px 500px at -10% 110%, rgba(255,255,255,.5), transparent 55%),
    var(--yellow);
  padding-block: clamp(2.5rem, 6vw, 5.5rem);
  overflow: hidden;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.hero-copy { max-width: 620px; }
#hero-title { font-size: clamp(2.1rem, 5vw, 3.7rem); }
.hero-lead { font-size: clamp(1.05rem, 1.4vw, 1.25rem); color: var(--ink-soft); max-width: 56ch; }

.hero-actions { display: flex; flex-wrap: wrap; gap: .9rem; margin: 1.8rem 0 1.6rem; }

.hero-badges {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-wrap: wrap; gap: .6rem 1.4rem;
  font-size: .95rem; font-weight: 600;
}
.hero-badges li { display: inline-flex; align-items: center; gap: .45rem; }

/* Hero media / placeholder zdjęcia */
.hero-media { display: flex; justify-content: center; }
.hero-photo { margin: 0; position: relative; width: 100%; max-width: 380px; }
.hero-img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: center 22%;
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  border: 5px solid var(--surface);
}
.photo-placeholder {
  aspect-ratio: 4 / 5;
  border-radius: var(--r-lg);
  background:
    repeating-linear-gradient(135deg, rgba(31,41,55,.05) 0 14px, transparent 14px 28px),
    linear-gradient(160deg, #fff, #fff7d6);
  border: 2px dashed rgba(31,41,55,.25);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .4rem;
}
.photo-initials {
  font-size: 3.4rem; font-weight: 800; letter-spacing: -0.04em;
  width: 110px; height: 110px; border-radius: 50%;
  background: var(--ink); color: var(--yellow);
  display: flex; align-items: center; justify-content: center;
}
.photo-note { font-size: .85rem; color: var(--ink-soft); text-transform: uppercase; letter-spacing: .14em; }
.hero-caption {
  position: absolute;
  left: 50%; bottom: -18px; transform: translateX(-50%);
  background: var(--ink); color: var(--on-dark);
  padding: .7rem 1.3rem; border-radius: 999px;
  display: flex; flex-direction: column; align-items: center;
  box-shadow: var(--shadow-md); white-space: nowrap;
}
.hero-caption strong { font-size: 1rem; }
.hero-caption span { font-size: .8rem; color: var(--on-dark-soft); }

/* ---------- O MNIE ---------- */
.about { background: var(--cream); }
.about-body p { color: var(--ink-soft); }
.about-body > p:first-of-type::first-letter {
  font-size: 3.4em; font-weight: 800; float: left;
  line-height: .8; padding: .05em .12em 0 0; color: var(--ink);
}
.pull-quote {
  margin: 2rem 0;
  padding: 1.6rem 1.8rem;
  border-left: 5px solid var(--yellow-deep);
  background: var(--surface);
  border-radius: var(--r-md);
  font-size: clamp(1.15rem, 2vw, 1.5rem);
  font-weight: 600;
  font-style: italic;
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}
.about-cta { text-align: center; margin-top: 2.2rem; }

/* ---------- OFERTA ---------- */
.offer { background: var(--surface); }
.offer-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: clamp(1.2rem, 3vw, 2rem);
  max-width: 880px; margin-inline: auto;
  align-items: stretch;
}
.offer-card {
  position: relative;
  display: flex; flex-direction: column;
  background: var(--cream);
  border: 1.5px solid var(--line);
  border-radius: var(--r-lg);
  padding: clamp(1.6rem, 3vw, 2.3rem);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease);
}
.offer-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: var(--yellow-deep); }
.offer-card--featured {
  background: var(--yellow);
  border-color: var(--ink);
}
.offer-tag {
  position: absolute; top: -14px; left: 50%; transform: translateX(-50%);
  background: var(--ink); color: var(--yellow);
  font-size: .76rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  padding: .35rem .9rem; border-radius: 999px; white-space: nowrap; margin: 0;
}
.offer-name { font-size: 1.4rem; margin-bottom: .35rem; }
.offer-desc { color: var(--ink-soft); font-size: .98rem; margin-bottom: 1.3rem; }
.offer-features { list-style: none; margin: 0 0 1.6rem; padding: 0; display: grid; gap: .7rem; }
.offer-features li {
  position: relative; padding-left: 1.9rem; font-weight: 500;
}
.offer-features li::before {
  content: "✓";
  position: absolute; left: 0; top: 0;
  width: 1.35rem; height: 1.35rem;
  background: var(--ink); color: var(--yellow);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: .8rem; font-weight: 800;
}
.offer-card-bottom { margin-top: auto; }
.offer-price { display: flex; align-items: baseline; gap: .25rem; margin: 0 0 1.1rem; }
.price-amount { font-size: 2.6rem; font-weight: 800; letter-spacing: -0.03em; }
.price-unit { font-size: 1.1rem; font-weight: 700; color: var(--ink-soft); }
.offer-foot { text-align: center; color: var(--ink-soft); margin: 2.2rem 0 0; font-size: .95rem; }

/* ---------- OPINIE (sekcja ciemna) ---------- */
.reviews { background: var(--ink); }
.reviews-grid {
  display: grid;
  gap: 1.6rem;
  max-width: 760px; margin-inline: auto;
}
.review-card {
  margin: 0;
  background: rgba(255,255,255,.04);
  border: 1px solid var(--line-dark);
  border-radius: var(--r-lg);
  padding: clamp(1.8rem, 3.5vw, 2.6rem);
}
.review-stars { color: var(--yellow-deep); font-size: 1.25rem; letter-spacing: .15em; margin-bottom: 1rem; }
.review-quote { margin: 0 0 1.6rem; }
.review-quote p { color: var(--on-dark); font-size: 1.08rem; margin: 0; }
.review-author { display: flex; align-items: center; gap: .9rem; }
.review-avatar {
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--yellow); color: var(--ink);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 1.2rem; flex-shrink: 0;
}
.review-author-meta { display: flex; flex-direction: column; line-height: 1.3; }
.review-author-meta strong { color: var(--on-dark); }
.review-author-meta span { color: var(--on-dark-soft); font-size: .9rem; }

/* ---------- KONTAKT / FORMULARZ ---------- */
.contact { background: var(--cream); }
.contact-form {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: clamp(1.6rem, 3.5vw, 2.6rem);
  box-shadow: var(--shadow-sm);
}
/* Honeypot — niewidoczny dla ludzi, dostępny dla botów (nie display:none) */
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem; }
.form-field { margin-bottom: 1.1rem; display: flex; flex-direction: column; }
.form-field label { font-weight: 700; margin-bottom: .4rem; font-size: .95rem; }
.req { color: #b45309; }
.form-field input,
.form-field select,
.form-field textarea {
  font: inherit;
  padding: .8rem .95rem;
  border: 2px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--cream);
  color: var(--ink);
  transition: border-color .18s var(--ease), background-color .18s var(--ease);
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: var(--ink);
  background: var(--surface);
  outline: none;
}
.form-field textarea { resize: vertical; min-height: 120px; }
.form-field input[aria-invalid="true"],
.form-field textarea[aria-invalid="true"] { border-color: #b91c1c; }
.field-error { color: #b91c1c; font-size: .88rem; font-weight: 600; margin: .45rem 0 0; }
.form-status { margin: 1.1rem 0 0; padding: .9rem 1.1rem; border-radius: var(--r-sm); font-weight: 600; }
.form-status.is-ok { background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; }
.form-status.is-err { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }

/* ---------- STOPKA ---------- */
.site-footer { background: var(--ink); color: var(--on-dark); padding-block: clamp(2.5rem, 5vw, 3.5rem); }
.footer-inner { display: grid; gap: 1.8rem; }
.footer-logo { color: var(--on-dark); font-size: 1.5rem; }
.footer-logo .logo-mark { background: var(--yellow); color: var(--ink); }
.footer-logo .logo-dot { color: var(--yellow); }
.footer-tagline { color: var(--on-dark-soft); max-width: 40ch; margin: .6rem 0 0; }
.footer-nav { display: flex; flex-wrap: wrap; gap: .4rem 1.4rem; }
.footer-nav a {
  color: var(--on-dark-soft); text-decoration: none; font-weight: 600;
  min-height: 44px; display: inline-flex; align-items: center;
}
.footer-nav a:hover { color: var(--on-dark); text-decoration: underline; }
.footer-bottom {
  border-top: 1px solid var(--line-dark);
  padding-top: 1.4rem;
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem;
  color: var(--on-dark-soft); font-size: .9rem;
}
.footer-bottom p { margin: 0; }
.footer-a11y { display: inline-flex; align-items: center; gap: .4rem; }
.footer-credit { margin: 1.2rem 0 0; font-size: .8rem; color: rgba(209,213,219,.55); }
.footer-credit a { color: rgba(209,213,219,.75); text-decoration: none; }
.footer-credit a:hover { color: var(--yellow); text-decoration: underline; }

/* =========================================================
   BANER COOKIES
   ========================================================= */
.cookie-banner {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 200;
  background: var(--ink);
  color: var(--on-dark);
  box-shadow: 0 -10px 40px rgba(31,41,55,.25);
  animation: cookie-up .35s var(--ease) both;
}
.cookie-banner[hidden] { display: none; }
.cookie-inner {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 3vw, 2.5rem);
  padding-block: 1.1rem;
  flex-wrap: wrap;
}
.cookie-text { flex: 1 1 320px; }
.cookie-title { font-weight: 800; margin: 0 0 .25rem; color: var(--on-dark); }
.cookie-text p:last-child { margin: 0; color: var(--on-dark-soft); font-size: .95rem; }
.cookie-text a { color: var(--yellow); }
.cookie-actions { display: flex; gap: .7rem; flex-wrap: wrap; }
.cookie-actions .btn { min-height: 46px; padding-block: .6rem; }
.cookie-actions .btn-ghost { color: var(--on-dark); border-color: var(--on-dark); }
.cookie-actions .btn-ghost:hover { background: var(--on-dark); color: var(--ink); }
.cookie-actions .btn-primary { background: var(--yellow); color: var(--ink); border-color: var(--yellow); }
.cookie-actions .btn-primary:hover { background: var(--yellow-deep); border-color: var(--yellow-deep); }

/* Panel granularny */
.cookie-panel {
  padding-bottom: 1.2rem;
  display: grid;
  gap: .9rem;
  border-top: 1px solid var(--line-dark);
  padding-top: 1.1rem;
  margin-top: .2rem;
}
.cookie-panel[hidden] { display: none; }
.cb-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.2rem;
}
.cb-option-info strong { display: block; color: var(--on-dark); }
.cb-option-info span { color: var(--on-dark-soft); font-size: .88rem; }
.cb-locked { color: var(--yellow); font-weight: 700; font-size: .85rem; white-space: nowrap; flex-shrink: 0; }
.cb-panel-actions { display: flex; justify-content: flex-end; }
.cb-panel-actions .btn { background: var(--yellow); color: var(--ink); border-color: var(--yellow); }
.cb-panel-actions .btn:hover { background: var(--yellow-deep); border-color: var(--yellow-deep); }

/* Przełącznik (switch) */
.cb-switch { position: relative; display: inline-block; width: 52px; height: 30px; flex-shrink: 0; cursor: pointer; }
.cb-switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.cb-slider {
  position: absolute; inset: 0;
  background: #4b5563;
  border-radius: 999px;
  transition: background-color .2s var(--ease);
}
.cb-slider::before {
  content: ""; position: absolute;
  width: 22px; height: 22px; left: 4px; top: 4px;
  background: #fff; border-radius: 50%;
  transition: transform .2s var(--ease);
}
.cb-switch input:checked + .cb-slider { background: var(--yellow); }
.cb-switch input:checked + .cb-slider::before { transform: translateX(22px); }
.cb-switch input:focus-visible + .cb-slider { outline: 3px solid var(--yellow); outline-offset: 2px; }

@keyframes cookie-up { from { transform: translateY(100%); } to { transform: none; } }

@media (max-width: 600px) {
  /* Hero */
  .hero { padding-top: 1.25rem; }
  #hero-title { font-size: clamp(1.85rem, 8vw, 2.3rem); }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; }
  .hero-photo { max-width: 260px; }
  /* Caption pod zdjęciem zamiast na nim — nie nachodzi na obraz */
  .hero-caption {
    position: static;
    transform: none;
    margin: .9rem auto 0;
    border-radius: 16px;
  }

  /* O mnie — mniejszy inicjał i lżejszy cytat */
  .about-body > p:first-of-type::first-letter { font-size: 2.6em; }
  .pull-quote { padding: 1.2rem 1.3rem; font-size: 1.12rem; }

  /* Oferta — luźniej */
  .offer-card { padding: 1.5rem 1.3rem; }

  /* Sekcje — mniejszy odstęp pionowy */
  .section { padding-block: clamp(3rem, 12vw, 4rem); }

  /* Baner cookies — czytelny układ przycisków */
  .cookie-actions { width: 100%; display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
  .cookie-actions [data-cookie="all"] { grid-column: 1 / -1; order: -1; }
  .cb-option { flex-direction: row; align-items: flex-start; }
}

/* =========================================================
   ANIMACJE (reveal on scroll) — wyłączane przy reduced motion
   ========================================================= */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.is-visible { opacity: 1; transform: none; }

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

/* =========================================================
   RESPONSYWNOŚĆ
   ========================================================= */
@media (max-width: 920px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-photo { max-width: 320px; }
}

@media (max-width: 760px) {
  .nav-toggle { display: flex; }
  .main-nav { position: relative; }
  .nav-list {
    position: absolute;
    top: calc(100% + 14px);
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: .25rem;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    box-shadow: var(--shadow-md);
    padding: .6rem;
    min-width: 220px;
    /* stan zamknięty */
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity .2s var(--ease), transform .2s var(--ease), visibility .2s;
  }
  .nav-list.is-open { opacity: 1; visibility: visible; transform: none; }
  .nav-list a { width: 100%; }
  .nav-cta { margin-left: 0; margin-top: .25rem; }

  .offer-grid { grid-template-columns: 1fr; max-width: 460px; }
  .form-row { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; }
}
