/* Text Block — Style Frontend */

.wp-block-bloc-th-text.text {
  padding: 60px 24px;
  max-width: 1200px;
  margin: 0 auto;
}

.text__container {
  max-width: 848px;
  margin: 0 auto;
}

.text__body {
  font-family: var(--font-body);
  font-size: var(--text-body);
  font-weight: 300;
  line-height: 23px;
  color: var(--color-text);
}

.text__body p {
  margin: 0 0 23px 0;
}

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

/* Variante PUB (Figma 859:15220) : texte 692 centré + encart 240x420 calé à droite, centré verticalement */
.wp-block-bloc-th-text.text--pub {
  max-width: 1440px;
}
.text--pub .text__container {
  max-width: 1392px;          /* 1440 − 2×24 */
  position: relative;
}
.text--pub .text__body {
  max-width: 692px;
  margin: 0 auto;             /* colonne de texte centrée */
}

.text__pub-sidebar {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 240px;
  height: 420px;
  background-color: #e7e7e7;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

.text__pub-sidebar > a { display: block; width: 100%; height: 100%; }
.text__pub-sidebar img { width: 100%; height: 100%; object-fit: cover; display: block; }

.text__pub-label {
  font-family: var(--font-body);
  font-size: 22.5px;
  font-weight: 400;
  color: #a9a9a9;
  line-height: 1.3;
}

/* Responsive */
/* Tablette : la variante pub passe l'encart sous le texte (l'absolu chevaucherait sinon) */
@media (max-width: 1024px) {
  .text--pub .text__pub-sidebar {
    position: static;
    transform: none;
    margin: 32px auto 0;
  }
  .text--pub .text__body {
    max-width: 692px;
  }
}

/* Mobile : pleine largeur, paddings réduits, zéro débordement */
@media (max-width: 768px) {
  .wp-block-bloc-th-text.text {
    padding: 40px 16px;
    box-sizing: border-box;
  }

  .text__container {
    box-sizing: border-box;
  }

  .text__pub-sidebar {
    position: static;
    transform: none;
    margin: 32px auto 0;
    width: 100%;
    max-width: 240px;
  }
}
