/* FOODIKU COMMUNITY YEARLY V1 (releasekandidaat, voorlopig Build 11; niet in Build 10).
   Alleen presentatie: de twee Home-kaarten (verkoop en leden), het EXTRA-blok bij Jaar op de paywall en het
   communityvenster (leden, welkom, verkoop). Hergebruikt de bestaande tokens (--green, --green-dark, --orange,
   --card-bg, --ink, --ink-soft, --radius-*) en de vormtaal van .account-card-compact en .notif-preprompt-*;
   verandert geen enkele bestaande regel. */

/* ---------- Home: de communitykaarten ---------- */

.home-community-card {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.3rem 0.85rem;
  align-items: center;
  background: linear-gradient(160deg, #f1f8f0 0%, var(--card-bg) 70%);
  border: 2px solid #d6ead4;
  border-radius: var(--radius-lg);
  padding: 1rem 1.1rem 1.1rem;
  box-shadow: 0 1px 2px rgba(43, 43, 40, 0.06), 0 10px 24px rgba(43, 43, 40, 0.07);
}

.home-community-copy {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  min-width: 0;
}

.home-community-eyebrow {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--green-dark);
}

.home-community-title {
  margin: 0;
  font-size: 1.28rem;
  font-weight: 900;
  line-height: 1.12;
  color: var(--ink);
}

.home-community-art {
  width: 80px;
  height: 80px;
  object-fit: contain;
  align-self: center;
}

.home-community-body {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-top: 0.3rem;
}

.home-community-lead {
  margin: 0;
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.35;
  color: var(--ink);
}

.home-community-text {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.38;
  color: var(--ink);
}

.home-community-punch {
  font-weight: 800;
  color: var(--green-dark);
}

.home-community-foot {
  margin: 0.1rem 0 0;
  padding: 0.4rem 0.7rem;
  border-radius: 10px;
  background: #e3f2e1;
  text-align: center;
  text-wrap: balance;
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.3;
  color: var(--green-dark);
}

.home-community-cta {
  grid-column: 1 / -1;
  margin-top: 0.5rem;
  min-height: 52px;
  padding: 0.85rem 1.2rem;
  font-size: 1rem;
}

/* Ledenkaart (Full Jaar): dezelfde vorm, sterker groen als bevestiging. */
.home-community-card-member {
  background: linear-gradient(160deg, #e3f2e1 0%, #f4faf3 55%, var(--card-bg) 100%);
  border-color: var(--green);
}

.home-community-card-member .home-community-title {
  color: var(--green-dark);
}

/* ---------- Paywall: EXTRA bij Jaar ---------- */

.paywall-plan-extra {
  display: inline-block;
  align-self: flex-start;
  width: fit-content;
  margin-top: 0.35rem;
  padding: 0.12rem 0.5rem;
  border-radius: 999px;
  background: #e3f2e1;
  font-size: 0.76rem;
  font-weight: 800;
  color: var(--green-dark);
}

.paywall-community {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.2rem 0.75rem;
  align-items: start;
  margin: 0 0 1rem;
  padding: 0.95rem 1rem;
  background: #f1f8f0;
  border: 2px solid var(--green);
  border-radius: var(--radius-md);
  text-align: left;
}

.paywall-community-art {
  grid-row: 1 / span 3;
  width: 64px;
  height: 64px;
  object-fit: contain;
}

.paywall-community-eyebrow {
  margin: 0;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--green-dark);
}

.paywall-community-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 900;
  line-height: 1.2;
  color: var(--ink);
}

.paywall-community-text {
  margin: 0;
  font-size: 0.85rem;
  font-weight: 600;
  line-height: 1.4;
  color: var(--ink);
}

/* Verkoopstand: dezelfde groene balk als "Exclusief inbegrepen bij FOODIKU Full Jaar." op de Home-kaart. */
.paywall-community-only {
  grid-column: 1 / -1;
  margin: 0.55rem 0 0;
  padding: 0.4rem 0.7rem;
  border-radius: 10px;
  background: #e3f2e1;
  text-align: center;
  text-wrap: balance;
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.3;
  color: var(--green-dark);
}

/* Jaarstand: de knop naar de Facebookgroep, zoals de knop van de ledenkaart op Home. */
.paywall-community-cta {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.65rem;
  min-height: 52px;
  padding: 0.85rem 1rem;
  font-size: 0.95rem;
  text-align: center;
  text-wrap: balance;
  text-decoration: none;
}

/* ---------- Het communityvenster ---------- */

.community-sheet-overlay {
  position: fixed;
  inset: 0;
  z-index: 61;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: calc(1rem + var(--safe-top)) 1rem calc(1rem + var(--safe-bottom));
  background: rgba(30, 26, 20, 0.5);
}

.community-sheet-card {
  position: relative;
  width: 100%;
  max-width: 420px;
  max-height: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  padding: 1.35rem 1.25rem 1.1rem;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
  animation: pop-in 0.25s ease;
}

.community-sheet-art {
  display: block;
  width: 100px;
  height: 100px;
  margin: 0 auto 0.4rem;
  object-fit: contain;
}

.community-sheet-eyebrow {
  margin: 0;
  text-align: center;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--green-dark);
}

.community-sheet-title {
  margin: 0.2rem 0 0.7rem;
  text-align: center;
  font-size: 1.4rem;
  font-weight: 900;
  line-height: 1.15;
  color: var(--ink);
  outline: none;
}

.community-sheet-body {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin: 0 0 1rem;
}

.community-sheet-lead {
  margin: 0;
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.4;
  color: var(--ink);
}

.community-sheet-text {
  margin: 0;
  font-size: 0.93rem;
  font-weight: 600;
  line-height: 1.45;
  color: var(--ink);
}

.community-sheet-note {
  margin: 0;
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1.4;
  color: var(--ink-soft);
}

.community-sheet-foot {
  margin: 0.1rem 0 0;
  padding: 0.4rem 0.7rem;
  border-radius: 10px;
  text-align: center;
  text-wrap: balance;
  background: #e3f2e1;
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--green-dark);
}

.community-sheet-card .btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 54px;
  padding: 0.9rem 0.8rem;
  font-size: 0.92rem;
  text-align: center;
  text-wrap: balance;
  text-decoration: none;
  box-sizing: border-box;
}

.community-sheet-footnote {
  margin: 0.55rem 0 0;
  text-align: center;
  font-size: 0.8rem;
  font-weight: 600;
  line-height: 1.4;
  color: var(--ink-soft);
}

.community-sheet-close {
  display: block;
  margin: 0.75rem auto 0;
}

/* Welkom: een grotere titel en een grotere illustratie (zonder label boven de titel). */
.community-sheet-overlay[data-variant="welcome"] .community-sheet-art {
  width: 128px;
  height: 128px;
}

.community-sheet-overlay[data-variant="welcome"] .community-sheet-title {
  margin-top: 0.55rem;
  font-size: 1.65rem;
  color: var(--green-dark);
}

/* Ledenvenster: de titel in groen, net als de ledenkaart. */
.community-sheet-overlay[data-variant="member"] .community-sheet-title {
  color: var(--green-dark);
}

@media (max-width: 359px) {
  .home-community-art {
    width: 68px;
    height: 68px;
  }
  .home-community-title {
    font-size: 1.12rem;
  }
  .home-community-lead {
    font-size: 0.95rem;
  }
  .home-community-text {
    font-size: 0.86rem;
  }
  .paywall-community-art {
    width: 52px;
    height: 52px;
  }
  .paywall-community-cta {
    font-size: 0.88rem;
    padding: 0.85rem 0.6rem;
  }
  .community-sheet-card {
    padding: 1.15rem 1rem 1rem;
  }
  .community-sheet-art,
  .community-sheet-overlay[data-variant="welcome"] .community-sheet-art {
    width: 88px;
    height: 88px;
  }
  .community-sheet-overlay[data-variant="welcome"] .community-sheet-title {
    font-size: 1.45rem;
  }
  .community-sheet-card .btn {
    font-size: 0.84rem;
    padding: 0.85rem 0.6rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .community-sheet-card {
    animation: none;
  }
}
