/* =====================================================
   ПОСТ — ОБНОВЛЁННЫЕ СТИЛИ (ИСПРАВЛЕННАЯ ВЕРСИЯ)
   Фикс: изображение в quote-with-photo на новом хостинге
   ===================================================== */


/* ─────────────────────────────────────────
   1. TOC — левое выравнивание с отступом через border
   ───────────────────────────────────────── */

   .toc-list {
    display: flex;
    flex-direction: column;
    align-items: stretch;
}

.toc-list a {
    display: block;
    width: 100%;
    text-align: left;
    padding: 14px 0;
    border-top: 1px solid rgba(226, 232, 240, 0.5);
    color: var(--Type-Primary, #111827);
    font-family: var(--Typography-Family-Primary, Manrope);
    font-size: var(--Typography-Size-16, 16px);
    font-weight: 700;
    line-height: 150%;
    transition: color 0.25s ease;
    padding-left: 0 !important;
}

.toc-list a:last-child {
    border-bottom: 1px solid rgba(226, 232, 240, 0.5);
}

/* h3 — тонкая серая полоска слева */
.toc-list a[data-level="3"] {
    padding-left: 12px !important;
    border-left: 2px solid #e2e8f0;
    font-weight: 600;
    font-size: 15px;
}

/* h4 — тонкая полоска слева + меньший шрифт */
.toc-list a[data-level="4"] {
    padding-left: 24px !important;
    border-left: 2px solid #e2e8f0;
    font-weight: 500;
    font-size: 14px;
    color: var(--Type-Secondary, #475569);
}

.toc-list a:hover {
    color: #f59e0b;
}

.toc-list a.active {
    color: var(--Type-Orange-Contrast, #e2920b);
}

/* Активный h3/h4 — меняем цвет полоски */
.toc-list a[data-level="3"].active,
.toc-list a[data-level="4"].active {
    border-left-color: #e2920b;
}


/* ─────────────────────────────────────────
   2. FEATURED IMAGE — не растягивать
   ───────────────────────────────────────── */

.main_photo_blog {
    width: 100%;
    border-radius: var(--Corners-20, 20px);
    overflow: hidden;
    max-height: 560px;
}

.main_photo_blog img {
    width: 100%;
    height: 100%;
    max-height: 560px;
    object-fit: cover;
    object-position: center;
    display: block;
    border-radius: var(--Corners-20, 20px);
}


/* ─────────────────────────────────────────
   3. ЦИТАТА — Pullquote (без фото)
   .wp-block-pullquote
   ───────────────────────────────────────── */

.text_blog .wp-block-pullquote {
    margin-block: 36px;
    padding: 24px;
    border-radius: var(--Corners-16, 16px);
    background: #ffdf9e;
    border: none;
    text-align: left;
}

.text_blog .wp-block-pullquote blockquote {
    margin: 0;
    padding: 0;
}

.text_blog .wp-block-pullquote p {
    color: var(--Type-Primary, #111827);
    font-family: var(--Typography-Family-Primary, Manrope);
    font-size: var(--Typography-Size-20, 20px);
    font-style: normal;
    font-weight: 500;
    line-height: 140%;
    margin-bottom: 24px;
}

.text_blog .wp-block-pullquote cite,
.text_blog .wp-block-pullquote .wp-block-pullquote__citation {
    display: block;
    font-style: normal;
    font-size: var(--Typography-Size-16, 16px);
    font-weight: 700;
    color: var(--Type-Primary, #111827);
    line-height: 150%;
}

/* Gutenberg Quote block (wp-block-quote) */
.text_blog .wp-block-quote {
    margin-block: 36px;
    padding: 24px 24px 24px 28px;
    border-radius: var(--Corners-16, 16px);
    background: #ffdf9e;
    border: none;
    border-left: 4px solid #e2920b;
}

.text_blog .wp-block-quote p {
    color: var(--Type-Primary, #111827);
    font-family: var(--Typography-Family-Primary, Manrope);
    font-size: var(--Typography-Size-20, 20px);
    font-weight: 500;
    line-height: 140%;
    margin-bottom: 16px;
}

.text_blog .wp-block-quote cite,
.text_blog .wp-block-quote footer {
    display: block;
    font-size: var(--Typography-Size-16, 16px);
    font-style: normal;
    font-weight: 700;
    color: var(--Type-Primary, #111827);
}


/* ─────────────────────────────────────────
   4. ЦИТАТА С ФОТО — .quote-with-photo
   ИСПРАВЛЕНО: жёсткие правила для нового хостинга
   ───────────────────────────────────────── */

.text_blog .wp-block-group.quote-with-photo {
    display: flex;
    gap: 24px;
    align-items: flex-start;
    margin-block: 36px;
    padding: 24px;
    border-radius: var(--Corners-16, 16px);
    background: #ffdf9e;
}

/* Фото — контейнер */
.text_blog .wp-block-group.quote-with-photo > .wp-block-image {
    flex-shrink: 0 !important;
    flex-grow: 0 !important;
    width: 160px !important;
    max-width: 160px !important;
    min-width: 160px !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* figure внутри wp-block-image */
.text_blog .wp-block-group.quote-with-photo > .wp-block-image figure {
    margin: 0 !important;
    padding: 0 !important;
    width: 160px !important;
    max-width: 160px !important;
}

/* Само изображение — КЛЮЧЕВОЕ исправление */
.text_blog .wp-block-group.quote-with-photo > .wp-block-image img,
.text_blog .wp-block-group.quote-with-photo > .wp-block-image figure img,
.text_blog .wp-block-group.quote-with-photo .wp-block-image img {
    width: 160px !important;
    height: 182px !important;
    max-width: 160px !important;
    min-width: 160px !important;
    object-fit: cover !important;
    object-position: center top !important;
    border-radius: 12px !important;
    display: block !important;
    /* Сброс глобального padding-top из .text_blog img */
    padding-top: 0 !important;
    margin: 0 !important;
}

/* Правая колонка */
.text_blog .wp-block-group.quote-with-photo > .wp-block-group {
    flex: 1;
    min-width: 0;
    background: transparent !important;
    padding: 0 !important;
    border: none !important;
    gap: 0;
}

/* Текст цитаты */
.text_blog .wp-block-group.quote-with-photo p {
    color: var(--Type-Primary, #111827);
    font-family: var(--Typography-Family-Primary, Manrope);
    font-size: var(--Typography-Size-20, 20px);
    font-weight: 500;
    line-height: 140%;
    margin-bottom: 16px;
}

/* Имя автора */
.text_blog .wp-block-group.quote-with-photo .quote-author {
    font-size: var(--Typography-Size-16, 16px) !important;
    font-weight: 700 !important;
    line-height: 150% !important;
    margin-bottom: 4px !important;
    color: var(--Type-Primary, #111827) !important;
}

/* Должность */
.text_blog .wp-block-group.quote-with-photo .quote-role {
    font-size: var(--Typography-Size-14, 14px) !important;
    font-weight: 500 !important;
    line-height: 130% !important;
    opacity: 0.8;
    margin-bottom: 0 !important;
    color: var(--Type-Primary, #111827) !important;
}

/* ─── Общие стили .quote-author / .quote-role (оба паттерна) ─── */
.text_blog .quote-author {
    font-size: var(--Typography-Size-16, 16px) !important;
    font-weight: 700 !important;
    line-height: 150% !important;
    margin-bottom: 4px !important;
    color: var(--Type-Primary, #111827) !important;
}

.text_blog .quote-role {
    font-size: var(--Typography-Size-14, 14px) !important;
    font-weight: 400 !important;
    line-height: 130% !important;
    opacity: 0.8;
    margin-bottom: 0 !important;
    color: var(--Type-Primary, #111827) !important;
}


/* ─────────────────────────────────────────
   4б. Простая цитата — Group.yellow без фото
   ───────────────────────────────────────── */

.text_blog .wp-block-group.yellow {
    margin-block: 36px;
    padding: 24px;
    border-radius: var(--Corners-16, 16px);
    background: #ffdf9e;
    gap: 0 !important;
}

/* Первый параграф = текст цитаты */
.text_blog .wp-block-group.yellow > p:first-child {
    font-size: var(--Typography-Size-20, 20px) !important;
    font-weight: 500 !important;
    line-height: 140% !important;
    margin-bottom: 16px !important;
}


/* ─────────────────────────────────────────
   5. ГЛОБАЛЬНЫЙ СБРОС padding-top для img
   ИСПРАВЛЕНО: убираем padding только там где нужно,
   не ломая цитаты с фото
   ───────────────────────────────────────── */

/* Сброс для всех картинок внутри группы/цитаты */
.text_blog .wp-block-group img {
    padding-top: 0 !important;
}

/* Сброс для картинок в pullquote */
.text_blog .wp-block-pullquote img,
.text_blog .wp-block-quote img {
    padding-top: 0 !important;
}


/* ─────────────────────────────────────────
   6. ADS_SUB — выравнивание кнопки по центру
   ───────────────────────────────────────── */

.text_blog .ads_sub {
    align-items: center !important;
}

.text_blog .ads_sub p {
    margin-bottom: 0 !important;
    line-height: 1 !important;
    display: flex !important;
    align-items: center !important;
}

.text_blog .ads_sub p a.btn1,
.text_blog .ads_sub a.btn1 {
    display: inline-flex !important;
    align-items: center !important;
    vertical-align: middle !important;
    margin-top: 0 !important;
    position: static !important;
}


/* ─────────────────────────────────────────
   7. FIGCAPTION — подпись к фото
   ───────────────────────────────────────── */

.text_blog .wp-block-image {
    margin-top: 48px;
    margin-bottom: 0;
}

.text_blog .wp-block-image img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: var(--Corners-12, 12px);
    padding-top: 0 !important;
}

.text_blog .wp-block-image figcaption,
.text_blog .wp-block-image .wp-element-caption {
    display: block;
    margin-top: 8px;
    margin-bottom: 36px;
    padding-left: 10px;
    border-left: 2px solid #5b7cff;
    color: var(--Type-Primary, #111827);
    font-family: var(--Typography-Family-Primary, Manrope);
    font-size: var(--Typography-Size-14, 14px);
    font-weight: 500;
    line-height: 150%;
    text-align: left !important;
}

.text_blog figure figcaption {
    display: block;
    margin-top: 8px;
    margin-bottom: 36px;
    padding-left: 10px;
    border-left: 2px solid #5b7cff;
    color: var(--Type-Primary, #111827);
    font-family: var(--Typography-Family-Primary, Manrope);
    font-size: var(--Typography-Size-14, 14px);
    font-weight: 500;
    line-height: 150%;
    text-align: left !important;
}

/* h5 как подпись (обратная совместимость) */
.text_blog h5 {
    color: var(--Type-Primary, #111827);
    font-family: var(--Typography-Family-Primary, Manrope);
    font-size: var(--Typography-Size-16, 16px);
    font-weight: 500;
    line-height: 150%;
    padding-left: 10px;
    border-left: 2px solid #5b7cff;
    margin-bottom: 45px;
    margin-top: 8px;
}


/* ─────────────────────────────────────────
   8. АДАПТИВ для quote-with-photo
   ───────────────────────────────────────── */

@media (max-width: 640px) {
    .text_blog .wp-block-group.quote-with-photo {
        flex-direction: column;
    }

    .text_blog .wp-block-group.quote-with-photo > .wp-block-image,
    .text_blog .wp-block-group.quote-with-photo > .wp-block-image figure {
        width: 100% !important;
        max-width: 100% !important;
        min-width: unset !important;
    }

    .text_blog .wp-block-group.quote-with-photo > .wp-block-image img,
    .text_blog .wp-block-group.quote-with-photo > .wp-block-image figure img,
    .text_blog .wp-block-group.quote-with-photo .wp-block-image img {
        width: 100% !important;
        max-width: 100% !important;
        min-width: unset !important;
        height: auto !important;
    }
}

.form-group {
    position: relative;
  }
  
  .wpcf7-not-valid-tip {
    position: absolute;
    bottom: -18px;
    left: 0;
    font-size: 12px;
    color: red;
  }


 
.text_blog .wp-block-pullquote,
.text_blog .wp-block-quote,
.text_blog .wp-block-group.yellow,
.text_blog .wp-block-group.quote-with-photo {
  font-family: var(--Typography-Family-Primary, Manrope);
  font-size: var(--Typography-Size-20, 20px);   
  line-height: 140%;                             
}


.text_blog .wp-block-pullquote p,
.text_blog .wp-block-quote p,
.text_blog .wp-block-group.yellow > p:first-child,
.text_blog .wp-block-group.quote-with-photo p {
  font-size: inherit !important;
  line-height: inherit !important;
}


.text_blog .wp-block-pullquote :is(ul,ol,li),
.text_blog .wp-block-quote :is(ul,ol,li),
.text_blog .wp-block-group.yellow :is(ul,ol,li),
.text_blog .wp-block-group.quote-with-photo :is(ul,ol,li) {
  font-size: inherit !important;
  line-height: inherit !important;
  font-family: inherit !important;
}

.text_blog a {
  color: #e2920b;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 2px;
}

.text_blog a:hover {
  color: #f59e0b;
}

.text_blog a:where(:not(.btn1)) {
  text-decoration: underline !important;
}


.text_blog em,
.text_blog i {
  font-family: inherit !important;
  font-style: italic !important;
  font-weight: inherit !important;
}

.text_blog strong em,
.text_blog strong i {
  font-family: inherit !important;
}


.text_blog .wp-block-pullquote > *:last-child,
.text_blog .wp-block-quote > *:last-child,
.text_blog .wp-block-group.yellow > *:last-child,
.text_blog .wp-block-group.quote-with-photo > *:last-child {
  margin-bottom: 0 !important;
}

.text_blog .wp-block-pullquote p:last-child,
.text_blog .wp-block-quote p:last-child,
.text_blog .wp-block-group.yellow p:last-child,
.text_blog .wp-block-group.quote-with-photo p:last-child {
  margin-bottom: 0 !important;
}

.text_blog .ads_sub p a.btn1,
.text_blog .ads_sub a.btn1 {
    display: inline-flex !important;
    align-items: center !important;
    vertical-align: middle !important;
    margin-top: 0 !important;
    position: static !important;
    background: #fff !important;
    color: #111827 !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 8px !important;
    text-decoration: none !important;
}

.text_blog .ads_sub p a.btn1:hover,
.text_blog .ads_sub a.btn1:hover {
    color: #e2920b !important;
    border-color: #e2920b !important;
    background: #fff !important;
    text-decoration: none !important;
}