/* ==========================================================================
   Site footer — parts/general/site-footer.php
   Colors/spacing eyeballed from Figma screenshots (Figma MCP hit its call
   rate limit mid-task, so exact hex/spacing tokens from the file itself
   couldn't be pulled — see chat notes). Swap the values under
   "design tokens" below once exact tokens are available; nothing else
   should need to change.
   Breakpoint: 767px, matching the rest of the theme (css/grid.css).
   ========================================================================== */

.wg-footer {
    /* ---- design tokens (approximate — verify against Figma) ---- */
    --wg-footer-bg: #FFFDF5;
    --wg-footer-text: #1A1A1A;
    --wg-footer-text-muted: #666666;
    --wg-footer-divider: #E7E1D2;
    --wg-footer-green: #6FB03E;
    --wg-footer-green-circle: #A4D249;
    --wg-footer-orange: #F2900E;
    --wg-footer-font: 'Noto Sans Hebrew', Arial, sans-serif;

    background-color: var(--wg-footer-bg);
    color: var(--wg-footer-text);
    font-family: var(--wg-footer-font);
    width: 100%;
    direction: rtl;
    text-align: right;
}

.wg-footer a {
    color: inherit;
    text-decoration: none;
}

.wg-footer__inner {
    max-width: 1120px;
    margin: 0 auto;
    padding: 48px 120px 40px;
    box-sizing: border-box;
}

.wg-footer__divider {
    border: none;
    border-top: 1px solid;
    color: #A4D249;
    width: calc(100% + 280px); /* Делаем линию шире родителя на 280px */
    margin: 28px -140px;
}

.wg-footer__category-label {
    color: #518112;
}

.wg-footer__logo-placeholder {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 120px;
    padding: 10px 14px;
    border: 1px dashed #c9c2ac;
    border-radius: 8px;
    color: #9a9a86;
    font-size: 12px;
    line-height: 1.3;
    text-align: center;
    background: rgba(255, 255, 255, 0.5);
}

.wg-footer__logo-placeholder--main {
    min-width: 200px;
    min-height: 70px;
    font-size: 14px;
    font-weight: 700;
}

.wg-footer__logo-image {
    display: block;
    max-width: 200px;
    height: auto;
}

.wg-footer__partner-logo-image {
    display: block;
    max-height: 64px;
    width: auto;
}

.wg-footer__logo-caption {
    margin: 6px 0 0;
    font-size: 12px;
    color: var(--wg-footer-text-muted);
    text-align: center;
    line-height: 1.5;
}

/* ==========================================================================
   Desktop (>= 768px)
   ========================================================================== */

.wg-footer--desktop {
    display: block;
}

.wg-footer--mobile {
    display: none;
}

.wg-footer--desktop .wg-footer__top {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 40px;
}

.wg-footer--desktop .wg-footer__main-logo {
    flex: 0 0 auto;
    text-align: center;
}

.wg-footer--desktop .wg-footer__about-text {
    flex: 1 1 auto;
    max-width: 900px;
    font-size: 14px;
    line-height: 1.9;
    color: var(--wg-footer-text);
    margin-right: 59px;
}

/* Categories row: partner logos first in the DOM (renders at the visual right in this
   RTL row) and the category list second (renders at the visual left). `space-between`
   pushes the two groups to opposite ends of the row instead of relying on manual margins. */
.wg-footer--desktop .wg-footer__categories {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 32px;
    margin-bottom: 50px;
}

/* Category icons are exported SVGs now (wg_footer_categories[].svg in the PHP),
   used directly as <img class="wg-footer__category-svg"> — no wrapper/border needed. */
.wg-footer__category-svg {
    width: 24px;
    height: 24px;
    object-fit: contain;
}

@media only screen and (max-width: 767px) {
    .wg-footer__category-svg {
        width: 20px;
        height: 20px;
    }
}

.wg-footer__category-list {
    display: flex;
    flex-direction: row;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 27px;
    margin-right: 110px;
}

.wg-footer__category-list a {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 500;
    white-space: nowrap;
}

.wg-footer--desktop .wg-footer__partner-logos {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 24px;
    /*flex-shrink: 0;
    scale: 1.2;
    padding-right: 10px;*/
}

.wg-footer__columns {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
    gap: 24px;
}

.wg-footer__col-title {
    margin: 0 0 16px;
    font-size: 15px;
    font-weight: 700;
}

.wg-footer__link-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.wg-footer__link-list li {
    margin-bottom: 12px;
    font-weight: 400; /* Убирает жирность */
    font-family: 'Noto Sans Hebrew New', 'Noto Sans Hebrew', Arial, sans-serif; /* Назначает новый шрифт */
    font-size: 15px;
}

.wg-footer__link-list a {
    display: flex;
    align-items: center;
    font-weight: 400; /* Дублируем на всякий случай для ссылок */
    font-family: 'Noto Sans Hebrew New', 'Noto Sans Hebrew', Arial, sans-serif;
    gap: 8px;
}

.wg-footer__link-list i {
    color: var(--wg-footer-green);
    font-size: 15px;
}

.wg-footer__col--about .wg-footer__about-grid {
    display: flex;
    flex-direction: row-reverse;
    gap: 40px;
}

.wg-footer__newsletter-label {
    margin: 40px 0 12px;
    font-size: 15px;
    font-weight: 600;
}

.wg-footer__newsletter-btn {
    display: inline-block;
    background-color: #ff7600;
    color: #fff;
    font-weight: 700;
    font-size: 15px;
    padding: 12px 24px;
    border-radius: 10px;
}

.wg-footer__col--meta {
    text-align: left;
}

.wg-footer__switcher {
    font-size: 15px;
    margin-bottom: 10px;
    cursor: pointer;
}

.wg-footer__switcher i {
    font-size: 10px;
    margin-inline-start: 4px;
}

.wg-footer__eco-badge {
    display: flex;
    align-items: center; /* Выравнивает иконку и текст по вертикали ровно в ряд */
    gap: 8px;
    font-size: 13px;
    color: var(--wg-footer-text-muted);
    margin-bottom: 16px;
    margin-right: 40px;
}


.wg-footer__weather-icon {
    width: 18px;         /* Задайте желаемый размер иконки (например, 16px или 18px) */
    height: 18px;
    object-fit: contain;
    color: var(--wg-footer-green); /* Если иконка SVG и поддерживает покраску через CSS */
}


.wg-footer__social {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 16px;
    margin-top: 32px;
    width: calc(100% + 280px);
    margin-left: -140px;
    margin-right: -140px;
    box-sizing: border-box;
}

/* Создаем левую и правую линии с помощью псевдоэлементов */
.wg-footer__social::before,
.wg-footer__social::after {
    content: "";
    flex: 1; /* Линия занимает всё доступное пространство по бокам */
    height: 1px; /* Толщина линии */
    background-color: #A4D249; /* Цвет дивайдера */
}

.wg-footer__social-img {
    width: 20px;
    height: 20px;
    object-fit: contain;
    display: block;
}

.wg-footer__social-circle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background-color: var(--wg-footer-green-circle);
    color: #fff;
    font-size: 18px;
}
/* ==========================================================================
   Логотип Tourisify вместо старого iframe
   ========================================================================== */

.footer-credit-link {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 30px auto 10px;
}
/* Отступ нужен только у третьего элемента ПЕРВОГО списка в блоке "אודות" */
.wg-footer__col--about .wg-footer__about-grid .wg-footer__link-list:first-child li:nth-child(3) {
    margin-bottom: 35px !important; /* Подберите нужную высоту отступа здесь */
}

.footer-credit-img {
    width: 60px;
    height: 17px;
    object-fit: contain;
    display: block;
}

.footer-credit-iframe {
    display: none !important;
}
/* ==========================================================================
   Mobile (< 768px)
   ========================================================================== */

@media only screen and (max-width: 767px) {

    .wg-footer--desktop {
        display: none;
    }

    .wg-footer--mobile {
        display: block;
    }

    .wg-footer__inner {
        padding: 32px 20px 28px;
    }

    .wg-footer--mobile .wg-footer__main-logo {
        display: flex;
    justify-content: center; /* Выравнивает логотип по центру */
    align-items: center;
    text-align: center;
    margin-bottom: 20px;
    }

    .wg-footer--mobile .wg-footer__main-logo img.wg-footer__logo-image {
    max-height: 56px; /* Устанавливаем высоту ровно 36px */
    width: auto;     /* Пропорциональная ширина */
    display: block;
    margin: 0 auto;             /* Центрирование */
}

.wg-footer__divider--mobile {
        border: none;
        border-top: 1px solid #A4D249;
        width: calc(100% - 5px);
        margin: 20px auto;     
    }

    .wg-footer__social-mobile {
        display: flex;
        flex-direction: row;
        justify-content: center;
        align-items: center;
        gap: 32px;
        margin-top: 24px;
        margin-bottom: 25px;
    }

    .wg-footer__newsletter-row {
        display: flex;
        flex-direction: row-reverse;
        align-items: center;
        justify-content: center;
        gap: 16px;
        margin-top: 24px;
    }

    .wg-footer__newsletter-row .wg-footer__newsletter-label {
        margin: 0;
    }

    .wg-footer__contact-row {
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        list-style: none;
        margin: 20px 0 0;
        padding: 0;
        border-bottom: 1px solid #A4D249;
        padding: 10px 10px;
        
    }

    .wg-footer__contact-row a {
        display: flex;
        flex-direction: column-reverse;
        align-items: center;
        gap: 4px;
        font-size: 13px;
        text-align: center;
    }

    .wg-footer__contact-row li {
        margin: 0; /* Небольшие внутренние отступы между колонками */
    }

    .wg-footer__accordion summary {
        display: flex;
        align-items: center;
        justify-content: space-between;
        list-style: none;
        padding: 16px 0;
        font-size: 15px;
        font-weight: 700;
        cursor: pointer;
    }

    .wg-footer__accordion summary::-webkit-details-marker {
        display: none;
    }

    .wg-footer__accordion-chevron {
        transition: transform 0.2s ease;
        font-size: 13px;
        color: var(--wg-footer-text-muted);
    }

    .wg-footer__accordion[open] .wg-footer__accordion-chevron {
        transform: rotate(180deg);
    }

   .wg-footer__accordion:first-of-type .wg-footer__link-list {
        display: flex;
        flex-direction: row; 
        align-items: center;
        gap: 42px;                 /* Расстояние между пунктами */
        padding-bottom: 12px;
        padding-bottom: 12px;
    }

    .wg-footer__accordion .wg-footer__link-list a {
        display: flex;
        flex-direction: row-reverse; /* Текст справа, иконка слева */
        align-items: center;
        text-decoration: none;
        color: inherit;
    }

    .wg-footer__accordion .wg-footer__link-list i.fab.fa-whatsapp {
        color: #000000;
        padding-left: 6px; /* Небольшой отступ слева */

    }

    .wg-footer__accordion .wg-footer__about-grid {
        display: flex;
        flex-direction: row-reverse; /* Правая колонка идет первой */
        justify-content: space-between;
        align-items: flex-start;
        gap: 20px;
        padding-bottom: 12px;
    }

    .wg-footer__about-grid .wg-footer__link-list:first-of-type li:nth-child(4) {
        margin-top: 28px; /* Увеличивайте или уменьшайте отступ в пикселях по вкусу */
    }


    .wg-footer__about-grid .wg-footer__link-list {
        display: flex;
        flex-direction: column !important;
        list-style: none;
        margin: 0;
        padding: 0;
        width: 50%;
    }

    .wg-footer__about-grid .wg-footer__link-list a {
        display: block !important;
        text-decoration: none;
        color: inherit;
        font-size: 13px;
        text-align: right !important;
    }

    .wg-footer__switcher--mobile {
        text-align: left !important;
        margin-top: 16px;
        font-size: 14px;
    }

    .wg-footer--mobile .wg-footer__about-text {
        margin-top: 20px;
        font-size: 13px;
        line-height: 1.8;
        color: #000000;
    }

    .wg-footer__partner-logos--mobile {
        display: flex;
        flex-direction: row-reverse; /* Сохраняем правильный порядок для иврита справа налево */
        justify-content: space-between; /* Растягивает логотипы по всей ширине строки */
        align-items: center;
        flex-wrap: nowrap;
        gap: 10px;
        margin-top: 24px;
        width: 100%;
    }

    .wg-footer__partner-logos--mobile .wg-footer__partner-img {
        max-height: 65px;  /* Ограничиваем высоту логотипов */
        width: auto;       /* Сохраняем пропорции */
        object-fit: contain;
        display: block;
    }

}
/* ==========================================================================
   Финальные правки: контакты, отступы и устранение конфликтов списка
   ========================================================================== */

/* 1. Настройка блока "צור קשר": иконки справа и черного цвета */
.wg-footer__col--contact .wg-footer__link-list a {
    display: flex;
    flex-direction: row-reverse;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
}

.wg-footer__col--contact .wg-footer__link-list i {
    color: #000000 !important;
    font-size: 14px;
    flex-shrink: 0;
}


.footer-credit-link {
    margin: 16px auto 48px !important;
}
/* =00. Настройка блока "הישארו מעודכנים": иконки справа и черного цвета */
.wg-footer__col--updates .wg-footer__link-list a {
    display: flex;
    flex-direction: row-reverse; /* Меняет местами иконку и текст для иврита */
    align-items: center;
    justify-content: flex-end;   /* Прижимаем вправо */
    gap: 8px;
}

.wg-footer__col--updates .wg-footer__link-list i {
    color: #000000 !important;   /* Черный цвет иконок */
    font-size: 14px;
    flex-shrink: 0;
}