/* ==========================================================================
   Lodziarnia śmietAnkowa — style wspólne
   ========================================================================== */

/* --- Kroje pisma ---------------------------------------------------------- */

@font-face {
  font-family: "Baloo Tammudu 2";
  src: url("../fonts/baloo-400.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Baloo Tammudu 2";
  src: url("../fonts/baloo-600.woff") format("woff");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Noticia Text";
  src: url("../fonts/noticia-400.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* --- Zmienne -------------------------------------------------------------- */

:root {
  /* kolory z projektu */
  --roz: #f29ca2;
  --roz-jasny: #fceff0;
  --bordo: #79112a;
  --zielen: #c5d393;
  --oliwka: #4d5703;
  --krem: #f7e8c9;
  --braz: #3c272e;
  --stopka-tlo: #675658;
  --smaki-tlo: #cecece;
  --biel: #fff;

  /* Kolor tekstu w menu i na belce filtrow.
     UWAGA: biel na rozu daje kontrast 2,09:1, ponizej progu WCAG (4,5:1).
     Zmiana tej jednej zmiennej na var(--bordo) daje 5,22:1. */
  --menu-kolor: var(--biel);

  /* Korekta pionowa dla Baloo Tammudu 2.
     Ten krój ma pole znaku wysokie na 2,296 em (wysokosc 1,177 + gleboko
     schodzaca 1,119), bo miesci znaki telugu. CSS centruje pole, nie litery,
     wiec wersaliki wypadaja o 0,272 em za wysoko. Ta wartosc to poprawka:
     (2,296 - 0,602) / 2 - (1,177 - 0,602) = 0,272 em. */
  --baloo-korekta: 0.272em;

  /* typografia */
  --font-naglowek: "Baloo Tammudu 2", "Trebuchet MS", sans-serif;
  --font-tekst: "Noticia Text", Georgia, serif;
  --tracking: 0.01em;

  /* wymiary */
  --belka-h: 100px;
  --belka-h-scroll: 80px;
  --filtry-h: 60px;
  /* 1440 z marginesem 60 daje 1320 px treści, czyli 4 kafelki po 330 px */
  --kontener: 1440px;
  --margines: 60px;
}

@media (max-width: 900px) {
  :root {
    --belka-h: 60px;
    --belka-h-scroll: 60px;
    --filtry-h: 48px;
    --margines: 20px;
  }
}

/* --- Reset i podstawy ----------------------------------------------------- */

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

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

body {
  margin: 0;
  font-family: var(--font-tekst);
  font-size: 20px;
  line-height: 1.5;
  color: var(--bordo);
  background: var(--roz);
}

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

a {
  color: inherit;
}

p {
  margin: 0 0 20px;
}

p:last-child {
  margin-bottom: 0;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-naglowek);
  letter-spacing: var(--tracking);
  margin: 0 0 20px;
  text-wrap: balance;
}

h1,
h2 {
  font-weight: 600;
  font-size: 38px;
  line-height: 1.3;
  text-transform: uppercase;
}

/* nazwa wlasna zapisana wersalikami wyglada zle, stad wyjatek */
.naglowek--nazwa {
  text-transform: none;
}

h3 {
  font-weight: 400;
  font-size: 24px;
  line-height: 1.4;
  text-transform: uppercase;
}

h4 {
  font-weight: 400;
  font-size: 22px;
  line-height: 1.4;
}

.tekst-mniejszy {
  font-size: 18px;
}

@media (max-width: 900px) {
  body {
    font-size: 18px;
  }

  h1,
  h2 {
    font-size: 28px;
  }

  h3 {
    font-size: 22px;
  }

  h4 {
    font-size: 20px;
  }

  .tekst-mniejszy {
    font-size: 16px;
  }
}

/* tresc tylko dla czytnikow ekranu */
.tylko-czytnik {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* skip link */
.pomin-do-tresci {
  position: absolute;
  left: 50%;
  top: 0;
  transform: translate(-50%, -150%);
  z-index: 200;
  background: var(--biel);
  color: var(--bordo);
  padding: 12px 20px;
  font-family: var(--font-naglowek);
  text-decoration: none;
  transition: transform 0.15s ease;
}

.pomin-do-tresci:focus {
  transform: translate(-50%, 0);
}

:focus-visible {
  outline: 3px solid var(--bordo);
  outline-offset: 2px;
}

.kontener {
  max-width: var(--kontener);
  margin: 0 auto;
  padding: 0 var(--margines);
}

/* --- Belka gorna ---------------------------------------------------------- */

.belka {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--roz);
  transition: transform 0.25s ease;
}

/* menu i filtry chowaja sie razem przy scrollu w dol */
.belka.jest-schowana {
  transform: translateY(-100%);
}

.belka__menu {
  height: var(--belka-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  transition: height 0.25s ease;
}

.belka.jest-przewinieta .belka__menu {
  height: var(--belka-h-scroll);
}

.belka__logo img {
  height: 40px;
  width: auto;
  transition: height 0.25s ease;
}

.belka.jest-przewinieta .belka__logo img {
  height: 34px;
}

.nawigacja ul {
  list-style: none;
  display: flex;
  gap: 40px;
  margin: 0;
  padding: 0;
}

.nawigacja a {
  font-family: var(--font-naglowek);
  font-weight: 400;
  font-size: 22px;
  letter-spacing: var(--tracking);
  text-transform: uppercase;
  text-decoration: none;
  color: var(--menu-kolor);
  position: relative;
  top: var(--baloo-korekta);
}

.nawigacja a:hover,
.nawigacja a:focus-visible,
.nawigacja a[aria-current="page"] {
  text-decoration: underline;
  text-underline-offset: 6px;
}

/* hamburger */
.hamburger {
  display: none;
  width: 44px;
  height: 44px;
  padding: 10px;
  margin-right: -10px;
  background: none;
  border: 0;
  cursor: pointer;
  color: var(--menu-kolor);
}

.hamburger span {
  display: block;
  height: 2px;
  background: currentColor;
  margin: 5px 0;
}

@media (max-width: 900px) {
  .belka__logo img {
    height: 25px;
  }

  .belka.jest-przewinieta .belka__logo img {
    height: 25px;
  }

  .hamburger {
    display: block;
  }

  .nawigacja {
    position: fixed;
    inset: var(--belka-h) 0 0;
    background: var(--roz);
    padding: 40px var(--margines);
    transform: translateX(100%);
    transition: transform 0.25s ease;
    overflow-y: auto;
  }

  .nawigacja[data-otwarte="tak"] {
    transform: translateX(0);
  }

  .nawigacja ul {
    flex-direction: column;
    gap: 28px;
  }

  .nawigacja a {
    font-size: 22px;
  }

  .zamknij-menu {
    position: relative;
    top: var(--baloo-korekta);
    margin-top: 40px;
    background: none;
    border: 0;
    padding: 10px 0;
    font-family: var(--font-naglowek);
    font-size: 22px;
    letter-spacing: var(--tracking);
    text-transform: uppercase;
    color: var(--menu-kolor);
    cursor: pointer;
  }
}

@media (min-width: 901px) {
  .zamknij-menu {
    display: none;
  }
}

/* --- Belka filtrow -------------------------------------------------------- */

.filtry {
  height: var(--filtry-h);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 40px;
}

.filtry fieldset {
  border: 0;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 40px;
}

.filtr {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  font-family: var(--font-naglowek);
  font-size: 18px;
  line-height: 1;
  letter-spacing: var(--tracking);
  text-transform: uppercase;
  color: var(--menu-kolor);
  min-height: 44px;
}

.filtr__tekst {
  display: block;
  transform: translateY(var(--baloo-korekta));
}

.filtr input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.filtr__pole {
  width: 18px;
  height: 18px;
  background: var(--biel);
  flex: none;
  display: grid;
  place-items: center;
}

.filtr__pole::after {
  content: "";
  width: 10px;
  height: 6px;
  border-left: 2.5px solid var(--bordo);
  border-bottom: 2.5px solid var(--bordo);
  transform: rotate(-45deg) scale(0);
  transition: transform 0.12s ease;
}

.filtr input:checked + .filtr__pole::after {
  transform: rotate(-45deg) scale(1);
}

.filtr input:focus-visible + .filtr__pole {
  outline: 3px solid var(--bordo);
  outline-offset: 2px;
}

@media (max-width: 900px) {
  .filtry,
  .filtry fieldset {
    gap: 24px;
  }

  .filtry {
    justify-content: center;
  }

  .filtr {
    font-size: 16px;
  }
}

/* --- Siatka smakow -------------------------------------------------------- */

.smaki-tlo {
  background: var(--smaki-tlo);
  padding: 50px 0;
}

.smaki {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  max-width: var(--kontener);
  margin: 0 auto;
  padding: 0 var(--margines);
}

/* przed przetasowaniem siatka jest ukryta, zeby kafelki nie przeskoczyly */
html.js .smaki:not([data-gotowe="tak"]) {
  visibility: hidden;
}

.smak {
  margin: 0;
  position: relative;
}

.smak img {
  width: 100%;
  aspect-ratio: 329 / 413;
  object-fit: cover;
}

.smaki__pusto {
  grid-column: 1 / -1;
  padding: 60px 0 100px;
  text-align: center;
}

@media (max-width: 900px) {
  .smaki {
    grid-template-columns: 1fr;
    padding: 0;
  }
}

/* --- Sekcje treści -------------------------------------------------------- */

.sekcja {
  height: 720px;
  overflow: hidden;
}

.sekcja--zielen,
.sekcja--krem {
  height: 820px;
}

.sekcja__wnetrze {
  height: 100%;
}

/* zdjecia siadaja na dolnej krawedzi sekcji i sa przy niej przycinane */
.sekcja__foto {
  align-self: end;
}

.sekcja__foto img {
  display: block;
}

.sekcja__wnetrze {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  column-gap: 20px;
  align-items: center;
}

/* Na telefonie projekt rozdziela pasy: zdjecie na kolorze pelnym,
   tekst na jasniejszym odcieniu tego samego koloru. */
.sekcja--roz {
  --tlo-foto: var(--roz);
  --tlo-tekst: #f8dadd;
  background: var(--roz);
  color: var(--bordo);
}

.sekcja--zielen {
  --tlo-foto: var(--zielen);
  --tlo-tekst: #e6f0c5;
  background: var(--zielen);
  color: var(--oliwka);
}

.sekcja--krem {
  --tlo-foto: var(--krem);
  --tlo-tekst: #fff4e2;
  background: var(--krem);
  color: var(--braz);
}

.sekcja--jasny-roz {
  background: var(--roz-jasny);
  color: var(--bordo);
}

.kol-foto-lewa {
  grid-column: 1 / 7;
  justify-self: center;
}

.kol-foto-prawa {
  grid-column: 7 / 13;
  justify-self: center;
}

/* blok tekstu ma 428 px, czyli cztery kolumny z gapami,
   i zostawia jedna kolumne marginesu od krawedzi */
.sekcja__tekst {
  width: 428px;
  max-width: 100%;
}

.kol-tekst-prawa {
  grid-column: 8 / 12;
}

.kol-tekst-lewa {
  grid-column: 2 / 6;
}

.kol-tekst-srodek {
  grid-column: 4 / 11;
}

.kol-foto-srodek {
  grid-column: 2 / 6;
  justify-self: center;
}

.foto--okragla {
  align-self: center;
}

.foto--okragla img {
  width: 428px;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 50%;
}

.sekcja img {
  width: 100%;
  height: auto;
}

@media (max-width: 900px) {
  .sekcja {
    height: auto;
    padding: 0 0 60px;
    background: var(--tlo-tekst);
  }

  .sekcja__foto {
    align-self: stretch;
  }

  .foto--okragla img {
    width: 240px;
  }

  .sekcja__foto {
    background: var(--tlo-foto);
    order: -1;
  }

  .sekcja__wnetrze {
    grid-template-columns: 1fr;
    row-gap: 40px;
  }

  .sekcja__wnetrze > * {
    grid-column: 1 !important;
  }

  .sekcja__tekst {
    width: auto;
  }

  .sekcja__tekst {
    text-align: center;
  }

  .sekcja--roz .sekcja__foto,
  .sekcja--zielen .sekcja__foto,
  .sekcja--krem .sekcja__foto {
    margin: 0 calc(var(--margines) * -1);
  }

  .foto--okragla {
    margin: 0 auto !important;
    max-width: 240px;
  }
}

/* --- Podstrona Zapraszamy ------------------------------------------------- */

.kontakt {
  list-style: none;
  margin: 32px 0 0;
  padding: 0;
  display: grid;
  gap: 16px;
}

.kontakt a {
  text-decoration: none;
}

.kontakt a:hover,
.kontakt a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 6px;
}

.kontakt a,
.kontakt > li > span {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  font-family: var(--font-naglowek);
  font-size: 26px;
  line-height: 1;
  letter-spacing: var(--tracking);
  min-height: 44px;
}

.kontakt__tekst {
  display: block;
  transform: translateY(var(--baloo-korekta));
}

.kontakt img {
  width: 28px;
  height: 28px;
  flex: none;
}

@media (max-width: 900px) {
  .kontakt {
    justify-items: center;
  }

  .kontakt a,
  .kontakt > li > span {
    font-size: 22px;
  }
}

/* --- Podstrony prawne ----------------------------------------------------- */

.dokument {
  padding: 80px 0 120px;
}

.dokument h1 {
  margin-bottom: 4px;
}

.dokument .data {
  margin-bottom: 40px;
}

.dokument h2 {
  font-size: 24px;
  font-weight: 400;
  margin-top: 40px;
}

/* --- Strona 404 ----------------------------------------------------------- */

.blad {
  background: var(--roz);
  height: 720px;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.blad__wnetrze {
  position: relative;
  width: 100%;
  max-width: var(--kontener);
  margin: 0 auto;
}

.blad__foto {
  width: 1267px;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
}

.blad__powrot {
  position: absolute;
  left: var(--margines);
  top: 50%;
  transform: translateY(-50%);
  margin: 0;
}

.blad .przycisk {
  border-color: var(--biel);
  color: var(--biel);
  /* 25 px daje wersaliki wysokie na 15 px, tak jak w projekcie */
  font-size: 25px;
  width: 395px;
  height: 80px;
}

.blad .przycisk:hover,
.blad .przycisk:focus-visible {
  background: var(--biel);
  color: var(--bordo);
}

@media (max-width: 900px) {
  .blad {
    height: auto;
    padding: 0 0 60px;
    display: block;
    text-align: center;
  }

  .blad__powrot {
    position: static;
    transform: none;
    margin-top: 24px;
    padding: 0 var(--margines);
  }

  .blad .przycisk {
    width: 100%;
    height: 56px;
  }
}

/* --- Stopka --------------------------------------------------------------- */

.stopka {
  background: var(--stopka-tlo);
  color: var(--biel);
  padding: 80px 0;
  font-size: 16px;
}

.stopka a {
  color: var(--biel);
}

.stopka__wnetrze {
  display: flex;
  align-items: center;
  gap: 40px;
}

.stopka__ikona {
  width: 75px;
  height: 75px;
  flex: none;
}

.stopka__some {
  display: flex;
  gap: 20px;
}

.stopka__some img {
  width: 35px;
  height: 35px;
}

.stopka__adres {
  font-style: normal;
  margin-left: auto;
}

.stopka__linki {
  list-style: none;
  margin: 0;
  padding: 0;
}

.stopka__prawa {
  text-align: left;
}

@media (max-width: 900px) {
  .stopka__wnetrze {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 24px;
  }

  .stopka__adres {
    margin-left: 0;
  }

  .stopka__some {
    order: 10;
  }
}

/* --- Baner cookies -------------------------------------------------------- */

/* Pozioma belka przy dolnej krawędzi: ma zasłaniać jak najmniej. */
.cookies {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 150;
  min-height: 65px;
  display: flex;
  align-items: center;
  gap: 40px;
  padding: 0 var(--margines);
  background: var(--biel);
  color: var(--bordo);
  font-size: 16px;
  line-height: 1.4;
}

.cookies[hidden] {
  display: none;
}

.cookies p {
  margin: 0;
}

.cookies a {
  color: inherit;
}

.cookies__przyciski {
  display: flex;
  gap: 28px;
  margin-left: auto;
  flex: none;
}

.przycisk {
  font-family: var(--font-naglowek);
  font-size: 18px;
  line-height: 1;
  letter-spacing: var(--tracking);
  text-transform: uppercase;
  /* gorne wypelnienie sciaga litery na os pionowa przycisku */
  padding: calc(var(--baloo-korekta) * 2) 8px 0;
  height: 44px;
  border: 2px solid var(--bordo);
  background: none;
  color: var(--bordo);
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}

.cookies .przycisk--zgoda {
  width: 100px;
}

.cookies .przycisk--odmowa {
  width: 200px;
}

.przycisk--glowny {
  background: var(--bordo);
  color: var(--biel);
}

@media (max-width: 900px) {
  .cookies {
    min-height: 160px;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 20px;
    padding: 20px var(--margines);
  }

  .cookies__przyciski {
    margin-left: 0;
    gap: 16px;
  }

}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
