/* ==========================================================================
   Moja Kuchnia 2.0 — strona główna (home.css)
   WYMAGA base.css (tokeny, przyciski, nagłówek, stopka) załadowanego wcześniej.
   Edytorialny kierunek: ciemna zieleń "Piec", krem "Śmietana", akcent "Szafran"
   Fraunces (display) + Inter (tekst)
   ========================================================================== */


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

html { scroll-behavior: smooth; scroll-padding-top: 96px; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
a { color: inherit; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; list-style: none; }
figure { margin: 0; }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 560;
  line-height: 1.06;
  letter-spacing: -0.015em;
  margin: 0 0 0.5em;
}
h1 { font-size: clamp(2.7rem, 5.6vw, 4.9rem); }
h2 { font-size: clamp(1.9rem, 3.4vw, 3.1rem); }
h3 { font-size: 1.32rem; line-height: 1.25; }

h1 em, h2 em {
  font-style: italic;
  font-weight: 480;
  color: var(--saffron);
}
.section h2 em { color: var(--green); }

.shell { width: min(100% - 40px, var(--shell)); margin-inline: auto; }

.sr-only {
  position: absolute; 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: 16px; top: -60px; z-index: 100;
  background: var(--ink); color: var(--cream);
  padding: 10px 16px; border-radius: 10px; text-decoration: none;
  transition: top 0.2s var(--ease-out);
}
.skip-link:focus { top: 12px; }

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

/* ------------------------------ hero ------------------------------ */
.hero {
  position: relative;
  background:
    radial-gradient(58rem 34rem at 82% -10%, rgba(47, 125, 82, 0.5), transparent 60%),
    radial-gradient(44rem 30rem at -8% 108%, rgba(232, 161, 60, 0.14), transparent 55%),
    linear-gradient(178deg, var(--forest-3), var(--forest) 42%, var(--forest-2));
  color: var(--cream);
  padding: clamp(140px, 17vh, 190px) 0 clamp(70px, 9vh, 110px);
  overflow: hidden;
}
.hero-glow {
  position: absolute; inset: 0; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='0.05'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

.hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(340px, 0.94fr);
  gap: clamp(36px, 5vw, 72px);
  align-items: center;
}

.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 0.86rem;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--muted-light);
  margin: 0 0 22px;
}
.hero-eyebrow .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--saffron);
  box-shadow: 0 0 0 5px rgba(232, 161, 60, 0.18);
}

.hero h1 { max-width: 13ch; }

.hero-lead {
  font-size: clamp(1.06rem, 1.5vw, 1.22rem);
  color: rgba(250, 245, 234, 0.78);
  max-width: 52ch;
  margin-top: 6px;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 32px; }

.hero-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 30px; }
.hero-tags li {
  font-size: 0.83rem; font-weight: 650;
  color: rgba(250, 245, 234, 0.82);
  border: 1px solid var(--line-dark);
  background: rgba(250, 245, 234, 0.05);
  padding: 6px 12px; border-radius: var(--r-pill);
}

/* scena hero: zdjęcie + karty */
.hero-stage { position: relative; }

.hero-photo {
  border-radius: var(--r-xl);
  overflow: hidden;
  transform: rotate(-1.6deg);
  box-shadow: var(--shadow-lg), 0 0 0 1px rgba(250, 245, 234, 0.1);
  will-change: transform;
}
.hero-photo img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; }

.float-card {
  position: absolute;
  background: rgba(250, 245, 234, 0.94);
  color: var(--ink);
  border-radius: 18px;
  box-shadow: var(--shadow-md);
  backdrop-filter: blur(8px);
  animation: floaty 6.5s ease-in-out infinite alternate;
  will-change: transform;
}
@keyframes floaty {
  from { translate: 0 -5px; }
  to   { translate: 0 7px; }
}

.fc-a {
  top: 7%; left: -9%;
  padding: 15px 18px;
  max-width: 240px;
  display: flex; flex-direction: column; gap: 3px;
}
.fc-a .fc-label {
  font-size: 0.72rem; font-weight: 800;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--saffron-deep);
}
.fc-a strong { font-size: 0.98rem; line-height: 1.3; transition: opacity 0.3s; }
.fc-a strong.is-fading { opacity: 0; }
.fc-a .fc-hint { font-size: 0.8rem; color: var(--muted); transition: opacity 0.3s; }
.fc-a .fc-hint.is-fading { opacity: 0; }

.fc-b {
  bottom: 16%; right: -7%;
  padding: 14px 18px;
  display: flex; align-items: center; gap: 13px;
  animation-delay: 1.4s;
}
.fc-b .fc-num {
  font-family: var(--font-display); font-weight: 600;
  font-size: 2.1rem; color: var(--green);
  line-height: 1;
}
.fc-b .fc-desc { font-size: 0.82rem; font-weight: 600; line-height: 1.35; color: var(--muted); }

.fc-c {
  bottom: -5%; left: 6%;
  padding: 12px 16px;
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 0.86rem; font-weight: 550;
  animation-delay: 2.6s;
}
.fc-c .fc-ico {
  display: grid; place-items: center;
  width: 30px; height: 30px; border-radius: 10px;
  background: var(--green); color: #fff; flex: none;
}

/* ------------------------------ marquee ------------------------------ */
.marquee {
  background: var(--forest-3);
  color: var(--saffron);
  border-block: 1px solid var(--line-dark);
  overflow: hidden;
  padding: 15px 0;
}
.marquee-track {
  display: flex; align-items: center; gap: 34px;
  width: max-content;
  white-space: nowrap;
  font-family: var(--font-display);
  font-style: italic; font-weight: 480;
  font-size: 1.18rem; letter-spacing: 0.02em;
  animation: marquee 30s linear infinite;
}
.marquee-track i { font-style: normal; font-size: 0.75rem; opacity: 0.55; }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee {
  to { transform: translateX(-50%); }
}

/* ------------------------------ sekcje ------------------------------ */
.section { padding: clamp(76px, 9vw, 128px) 0; }

.eyebrow {
  display: inline-block;
  font-weight: 750; font-size: 0.82rem;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--green);
  margin: 0 0 14px;
}
.eyebrow-light { color: var(--saffron); }

.section-head { max-width: 720px; margin: 0 auto 52px; text-align: center; }
.section-head h2 { margin-bottom: 14px; }
.section-lead { color: var(--muted); font-size: 1.08rem; }

/* intro */
.intro { padding-block: clamp(70px, 8vw, 110px); }
.intro-grid { max-width: 880px; text-align: center; }
.intro-title { font-size: clamp(2rem, 4vw, 3.4rem); }
.intro-text { color: var(--muted); font-size: clamp(1.05rem, 1.5vw, 1.2rem); max-width: 62ch; margin-inline: auto; }

/* ------------------------------ bento ------------------------------ */
.bento {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 22px;
}
.bento-card {
  grid-column: span 4;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}
.bento-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }

.b-lodowka { grid-column: span 7; }
.b-zakupy { grid-column: span 5; }
.b-jadlospis { grid-column: span 5; }
.b-przepisy { grid-column: span 7; }
.b-family { grid-column: span 7; }
.b-ai { grid-column: span 5; }
.b-sync { grid-column: span 12; }

.bento-media { overflow: hidden; }
.bento-media img {
  width: 100%; height: 100%;
  aspect-ratio: 16 / 9.4;
  object-fit: cover;
  transition: transform 0.7s var(--ease-out);
}
.b-zakupy .bento-media img, .b-jadlospis .bento-media img { aspect-ratio: 4 / 2.75; }
.bento-card:hover .bento-media img { transform: scale(1.045); }

.bento-body { padding: 24px 26px 26px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.bento-body h3 { margin-bottom: 6px; }
.bento-body p { color: var(--muted); margin-bottom: 0; font-size: 0.99rem; }

.bento-card.is-text { justify-content: center; }
.bento-card.is-text .bento-body { padding-block: 34px; }
.bento-card.is-tint {
  background: linear-gradient(150deg, #fdf4e2, #fbeacb);
  border-color: #efd9ae;
}
.mini-badge {
  align-self: flex-start;
  font-size: 0.78rem; font-weight: 800;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--saffron-deep);
  margin-bottom: 10px;
}
.b-sync .bento-body { padding-block: 30px; text-align: center; align-items: center; }
.b-sync p { max-width: 68ch; }

.chip-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.chip-row li {
  font-size: 0.82rem; font-weight: 650;
  color: var(--green-strong);
  background: rgba(47, 125, 82, 0.09);
  border: 1px solid rgba(47, 125, 82, 0.2);
  padding: 6px 12px; border-radius: var(--r-pill);
}

/* ------------------------------ kroki ------------------------------ */
.steps-section { background: var(--cream-2); }
.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 26px;
  counter-reset: step;
  position: relative;
}
.steps::before {
  content: "";
  position: absolute; top: 34px; left: 6%; right: 6%;
  border-top: 2px dashed rgba(47, 125, 82, 0.3);
}
.step { position: relative; padding-top: 8px; }
.step-num {
  position: relative; z-index: 1;
  display: grid; place-items: center;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--paper);
  border: 2px solid var(--green);
  color: var(--green-strong);
  font-family: var(--font-display); font-weight: 600; font-size: 1.5rem;
  margin-bottom: 18px;
  box-shadow: var(--shadow-sm);
  transition: background 0.3s, color 0.3s, transform 0.3s var(--ease-out);
}
.step:hover .step-num { background: var(--green); color: #fff; transform: scale(1.07); }
.step h3 { font-size: 1.18rem; margin-bottom: 6px; }
.step p { color: var(--muted); font-size: 0.96rem; margin: 0; }

/* ------------------------------ galeria ------------------------------ */
.gallery-section { padding-bottom: clamp(80px, 10vw, 140px); }
.gallery-section .section-head { margin-bottom: 40px; }

.gallery-marquee { overflow: hidden; }
.gallery-track {
  display: flex;
  align-items: flex-start;
  gap: 22px;
  width: max-content;
  padding-block: 18px 28px;
  animation: marquee 55s linear infinite;
}
.gallery-marquee:hover .gallery-track { animation-play-state: paused; }

.dish {
  position: relative;
  width: clamp(210px, 22vw, 280px);
  aspect-ratio: 4 / 5;
  flex: none;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--paper);
  box-shadow: var(--shadow-sm);
  transition: transform 0.4s var(--ease-out), box-shadow 0.4s var(--ease-out);
}
.dish:nth-child(odd) { rotate: -1.2deg; }
.dish:nth-child(even) { rotate: 1.2deg; translate: 0 14px; }
.dish:hover { transform: scale(1.04); box-shadow: var(--shadow-md); z-index: 2; }
.dish img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.dish::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 34%;
  background: linear-gradient(to top, rgba(20, 31, 25, 0.36), transparent);
  pointer-events: none;
}
.dish figcaption {
  position: absolute;
  z-index: 1;
  left: 14px;
  bottom: 14px;
  max-width: calc(100% - 28px);
  background: rgba(250, 245, 234, 0.94);
  color: var(--ink);
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.3;
  padding: 7px 13px;
  border-radius: var(--r-pill);
  backdrop-filter: blur(5px);
  box-shadow: 0 5px 16px rgba(20, 31, 25, 0.12);
}

/* ------------------------------ plany ------------------------------ */
.plans {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  align-items: stretch;
}
.plan {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 32px 30px 34px;
  display: flex; flex-direction: column;
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}
.plan:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }

.plan.is-featured {
  background: var(--forest);
  color: var(--cream);
  border-color: var(--forest);
  box-shadow: var(--shadow-lg);
}
.plan.is-featured .plan-desc, .plan.is-featured .checks li { color: rgba(250, 245, 234, 0.8); }
.plan.is-featured .checks li::before { background: var(--saffron); color: var(--forest-3); }

.plan-star {
  position: absolute; top: -15px; left: 50%; translate: -50% 0;
  background: var(--saffron); color: var(--forest-3);
  font-size: 0.78rem; font-weight: 800;
  letter-spacing: 0.05em; text-transform: uppercase;
  padding: 7px 16px; border-radius: var(--r-pill);
  white-space: nowrap;
  box-shadow: 0 8px 20px rgba(232, 161, 60, 0.35);
  margin: 0;
}
.plan-tag {
  font-size: 0.78rem; font-weight: 750;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--saffron-deep);
  margin: 0 0 10px;
}
.plan h3 { font-size: 2rem; margin-bottom: 8px; }
.plan-desc { color: var(--muted); font-size: 0.96rem; }

.checks { display: flex; flex-direction: column; gap: 11px; margin-top: 16px; }
.checks li {
  position: relative;
  padding-left: 30px;
  font-size: 0.95rem; color: var(--muted);
  line-height: 1.5;
}
.checks li::before {
  content: "✓";
  position: absolute; left: 0; top: 2px;
  display: grid; place-items: center;
  width: 19px; height: 19px; border-radius: 50%;
  background: rgba(47, 125, 82, 0.14);
  color: var(--green-strong);
  font-size: 0.72rem; font-weight: 800;
}
.checks li.is-unavailable::before {
  content: "–";
  background: rgba(95, 103, 98, 0.12);
  color: var(--muted);
}
.plan-cta { margin-top: 26px; }

.legal-note {
  text-align: center;
  color: var(--muted);
  font-size: 0.86rem;
  margin: 34px auto 0; max-width: 62ch;
}
.legal-note a {
  color: var(--forest);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

/* ------------------------------ CTA pobierania ------------------------------ */
.cta-download {
  position: relative;
  color: var(--cream);
  padding: clamp(96px, 12vw, 160px) 0;
  overflow: hidden;
  background: var(--forest-3);
}
.cta-bg {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0.55;
}
.cta-download::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(13, 32, 21, 0.72), rgba(13, 32, 21, 0.5) 45%, rgba(13, 32, 21, 0.78));
}
.cta-inner { position: relative; z-index: 1; text-align: center; max-width: 760px; }
.cta-inner h2 { font-size: clamp(2.2rem, 4.4vw, 3.7rem); }
.cta-inner h2 em { color: var(--saffron); }
.cta-lead { color: rgba(250, 245, 234, 0.82); font-size: 1.1rem; max-width: 56ch; margin-inline: auto; }
.cta-actions {
  display: flex; flex-wrap: wrap; gap: 16px;
  justify-content: center; margin-top: 34px;
}
.store-btn {
  display: inline-flex; align-items: center; gap: 13px;
  background: var(--cream); color: var(--forest-3);
  text-decoration: none;
  padding: 12px 24px; border-radius: 16px;
  box-shadow: var(--shadow-md);
  transition: transform 0.22s var(--ease-out), box-shadow 0.22s var(--ease-out);
}
.store-btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.store-btn span { display: flex; flex-direction: column; text-align: left; line-height: 1.15; }
.store-btn small { font-size: 0.74rem; font-weight: 600; opacity: 0.75; }
.store-btn strong { font-size: 1.12rem; font-weight: 800; letter-spacing: -0.01em; }

/* ------------------------------ prywatność ------------------------------ */
.privacy-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.privacy-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 26px 24px;
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
}
.privacy-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-sm); }
.pc-ico {
  display: grid; place-items: center;
  width: 44px; height: 44px; border-radius: 13px;
  background: rgba(47, 125, 82, 0.12);
  color: var(--green-strong);
  margin-bottom: 16px;
}
.privacy-card h3 { font-size: 1.14rem; margin-bottom: 6px; }
.privacy-card p { color: var(--muted); font-size: 0.93rem; margin: 0; }

.privacy-actions {
  display: flex; flex-wrap: wrap; gap: 12px;
  justify-content: center; margin-top: 38px;
}

/* ------------------------------ konto ------------------------------ */
.account-section { background: var(--cream-2); }
.account-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 24px; align-items: start;
}
.account-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 34px 32px;
}
.account-card.is-soft { background: #fdf9f0; }
.account-card h2 { font-size: clamp(1.5rem, 2.4vw, 2rem); }
.account-card > p { color: var(--muted); font-size: 0.98rem; }

.mini-steps { counter-reset: ms; display: flex; flex-direction: column; gap: 12px; margin: 18px 0 4px; }
.mini-steps li {
  counter-increment: ms;
  position: relative; padding-left: 40px;
  font-size: 0.95rem; color: var(--muted); line-height: 1.5;
}
.mini-steps li::before {
  content: counter(ms);
  position: absolute; left: 0; top: 0;
  display: grid; place-items: center;
  width: 27px; height: 27px; border-radius: 50%;
  background: var(--forest); color: var(--cream);
  font-family: var(--font-display); font-size: 0.9rem; font-weight: 600;
}
.account-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }

/* ------------------------------ kontakt ------------------------------ */
.contact-cta { text-align: center; }
.contact-inner { max-width: 620px; }
.contact-inner p { color: var(--muted); }
.contact-inner .btn { margin-top: 10px; }

/* ------------------------------ animacje wejścia ------------------------------ */
html.js [data-anim] {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
  transition-delay: var(--d, 0s);
  will-change: opacity, transform;
}
html.js [data-anim].is-in { opacity: 1; transform: none; }

/* ------------------------------ responsywność ------------------------------ */
@media (max-width: 1060px) {
  .top-links { display: none; }
  .nav-burger { display: block; }

  .bento-card,
  .b-lodowka, .b-zakupy, .b-jadlospis, .b-przepisy, .b-family, .b-ai { grid-column: span 6; }
  .b-sync { grid-column: span 12; }

  .privacy-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); row-gap: 40px; }
  .steps::before { display: none; }
  .footer-main { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 780px) {
  body { font-size: 1rem; }
  .hero { padding-top: 120px; }
  .hero-grid { grid-template-columns: 1fr; gap: 54px; }
  .hero h1 br { display: none; }
  .hero-stage { max-width: 460px; margin-inline: auto; width: 100%; }
  .fc-a { left: -4px; }
  .fc-b { right: -4px; }
  .fc-c { left: 10px; bottom: -18px; }

  .bento-card,
  .b-lodowka, .b-zakupy, .b-jadlospis, .b-przepisy, .b-family, .b-ai, .b-sync { grid-column: span 12; }
  .b-sync .bento-body { text-align: left; align-items: flex-start; }

  .plans { grid-template-columns: 1fr; max-width: 480px; margin-inline: auto; }
  .plan.is-featured { order: -1; }

  .account-grid { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .privacy-grid { grid-template-columns: 1fr; }
  .footer-main { grid-template-columns: 1fr; gap: 28px; }
  .footer-bottom { flex-direction: column; }
}

/* ------------------------------ dostępność: ruch ------------------------------ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001s !important;
  }
  .marquee-track, .gallery-track { animation: none; }
  .float-card { animation: none; }
  html.js [data-anim] { opacity: 1; transform: none; }
  .hero-photo { transform: none; }
}


