/* assets/css/components/_page-builder.css
 * WordPress additions for the ACF Flexible Content page builder
 * (template-parts/builder/*). The blocks themselves reuse the original
 * design CSS (pages/_general-content.css, components/_newsletter.css,
 * components/_faq-accordion.css) — this file only covers what the static
 * HTML didn't need: layout variants, CMS-rich text, and new blocks.
 */

/* --- Page header (pages without a "באנר פתיחה" block) ---------------- */
.pivot-page-header {
  max-width: 1300px;
  margin-inline: auto;
  padding: 40px 24px 24px;
  box-sizing: border-box;
  direction: rtl;
  text-align: right;
}

.pivot-page-header__title {
  margin: 8px 0 0;
  font-family: 'Fredoka', var(--font-main);
  font-weight: 400;
  font-size: 56px;
  line-height: 1.2;
  color: #000080;
}

@media (max-width: 767px) {
  .pivot-page-header__title { font-size: 36px; }
}

/* --- Rich text (WYSIWYG) -------------------------------------------- */
/* Editor paragraphs get the design's .pivot-philosophy__paragraph type. */
.pivot-philosophy__content.pivot-richtext {
  font-family: 'Fredoka', sans-serif;
  font-weight: 400;
  font-size: 21px;
  line-height: 32px;
  color: #183B51;
  text-align: right;
}

/* Spacing between paragraphs comes from the card's flex gap (31px). */
.pivot-philosophy__content.pivot-richtext > * {
  width: 100%;
  margin: 0;
}

@media (max-width: 992px) {
  .pivot-philosophy__content.pivot-richtext { font-size: 18px; line-height: 28px; }
}

@media (max-width: 576px) {
  .pivot-philosophy__content.pivot-richtext { font-size: 16px; line-height: 26px; }
}

.pivot-richtext > :first-child { margin-top: 0; }
.pivot-richtext > :last-child  { margin-bottom: 0; }

.pivot-richtext p,
.pivot-richtext ul,
.pivot-richtext ol {
  margin: 0 0 1em;
}

.pivot-richtext ul,
.pivot-richtext ol {
  padding-inline-start: 1.4em;
}

.pivot-richtext ul { list-style: disc; }
.pivot-richtext ol { list-style: decimal; }

.pivot-richtext li + li { margin-top: 0.35em; }

.pivot-richtext a {
  color: #000080;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.pivot-richtext strong { font-weight: 700; }

.pivot-richtext h2,
.pivot-richtext h3,
.pivot-richtext h4 {
  margin: 1.4em 0 0.5em;
  font-family: 'Fredoka', var(--font-main);
  font-weight: 500;
  color: #000080;
}

.pivot-editor-content {
  padding-bottom: 80px;
}

/* --- Values: 1–2 items ---------------------------------------------- */
.pivot-values__grid--1,
.pivot-values__grid--2 {
  justify-content: center;
}

/* --- Zig-zag: image side (design default = image on the right) ------- */
@media (min-width: 1025px) {
  .pivot-learning--image-left .pivot-learning__container {
    flex-direction: row;
  }
}

/* --- Projects: header follows the active slide ----------------------- */
[data-project-title],
[data-project-description] {
  transition: opacity 0.2s ease;
}

.pivot-revolution.is-switching [data-project-title],
.pivot-revolution.is-switching [data-project-description] {
  opacity: 0;
}

.pivot-revolution__gallery-wrapper--single {
  justify-content: center;
}

/* --- Quote block (founder-quote design from SignIn.html) ------------- */
.founder-quote-section {
  max-width: 1362px;
  min-height: 436px;
  margin: 0 auto 100px;
  display: flex;
  direction: rtl;
  align-items: center;
  justify-content: space-between;
  gap: 60px;
  padding-inline: 70px;
}

.quote-text-block {
  flex: 1;
  margin: 0;
  font-family: 'Fredoka', var(--font-main);
  font-weight: 400;
  font-size: 42px;
  line-height: 54px;
  color: #000080;
  text-align: right;
}

.quote-text-block p { margin: 0; }

.quote-text-block .highlight,
.pivot-quote__text strong,
.pivot-quote__text b {
  color: #C22DAF;
  font-weight: inherit;
}

.founder-card {
  width: 288px;
  min-height: 435px;
  margin: 0;
  border-radius: 20px;
  background: #FFFFFF;
  box-shadow: 0px 20px 40px rgba(0, 0, 0, 0.06);
  padding: 21px 14px 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  box-sizing: border-box;
  flex-shrink: 0;
}

.founder-img {
  width: 259px;
  height: 324px;
  border-radius: 12px;
  object-fit: cover;
  margin-bottom: 12px;
}

.founder-name {
  font-family: 'Fredoka', var(--font-main);
  font-weight: 500;
  font-size: 22px;
  line-height: 32px;
  color: #000080;
}

.founder-role {
  font-family: 'Fredoka', var(--font-main);
  font-weight: 500;
  font-size: 18px;
  line-height: 28px;
  color: #183B51;
}

.pivot-quote--text-only {
  justify-content: center;
  min-height: 0;
}

.pivot-quote--text-only .quote-text-block {
  flex: 0 1 900px;
  text-align: center;
}

@media (max-width: 1024px) {
  .founder-quote-section {
    flex-direction: column;
    text-align: center;
    padding-inline: 24px;
    gap: 32px;
  }
  .quote-text-block {
    text-align: center;
    font-size: 30px;
    line-height: 40px;
  }
}

/* --- Inspiration line (under the newsletter) ------------------------- */
.pivot-inspiration {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  max-width: 960px;
  margin: 40px auto 80px;
  padding-inline: 24px;
  text-align: center;
  direction: rtl;
}

.pivot-inspiration__icon {
  width: 58px;
  height: auto;
}

.pivot-inspiration__text {
  margin: 0;
  font-family: 'Fredoka', var(--font-main);
  font-weight: 400;
  font-size: 32px;
  line-height: 1.35;
  color: #000080;
}

.pivot-inspiration__text strong,
.pivot-inspiration__text b {
  color: #C22DAF;
  font-weight: inherit;
}

@media (max-width: 767px) {
  .pivot-inspiration__text { font-size: 24px; }
}

/* --- FAQ block (design accordion) ----------------------------------- */
/* smooth-accordion.js animates the height; the chevron follows .is-open so
   it turns back as soon as closing starts (not when the slide ends). */
[data-smooth-accordion].is-ready .accordion__item[open] .accordion__icon {
  transform: none;
}

[data-smooth-accordion].is-ready .accordion__item.is-open .accordion__icon {
  transform: rotate(180deg);
}

/* WYSIWYG answers */
/* The design styles .accordion__body p; editor answers may also hold lists,
   links or several paragraphs. */
.accordion__body > * + * {
  margin-top: 12px;
}

.accordion__body ul,
.accordion__body ol {
  margin: 0;
  padding-inline-start: 1.4em;
  font-family: 'Fredoka', sans-serif;
  font-size: 18px;
  line-height: 28px;
  color: #193A51;
}

.accordion__body ul { list-style: disc; }
.accordion__body ol { list-style: decimal; }

.accordion__body a {
  color: #000080;
  text-decoration: underline;
}
