/*
 Theme Name:     Divi Child
 Theme URI:      https://www.elegantthemes.com/gallery/divi/
 Description:    Divi Child Theme
 Author:         Elegant Themes
 Author URI:     https://www.elegantthemes.com
 Template:       Divi
 Version:        1.0.0
*/
 
 
/* =Theme customization starts here
------------------------------------------------------- */

.wpml-ls-legacy-list-horizontal ul { padding-bottom: 0 !important; }
.wpml-ls-legacy-list-horizontal a { padding: 5px 5px 6px !important; }

body #page-container .has_et_pb_sticky .et_pb_section .et_pb_button_0_tb_header { background-color: #4257ff; }

.single-post #et-main-area .et_pb_row { width:100%; max-width:1200px; }
@media only screen and (min-width: 1500px) {
  .single-post #main-content .et_pb_section {
    padding: 0 0 50px !important;    
  }
}

/* **** MENU **** */

/* testo menu */
.et_pb_menu_0_tb_header.et_pb_menu ul li a {
  font-size: 14px !important;
}

@media only screen and (max-width: 1260px) {

    /* Nasconde il menu desktop */
    #et_top_nav,
    #top-menu-nav,
    .et_pb_menu__menu,
    .et_pb_fullwidth_menu .et_pb_menu__menu {
        display: none !important;
    }

    /* Mostra l'hamburger */
    #et_mobile_nav_menu,
    .et_mobile_nav_menu,
    .et_pb_menu__wrap .mobile_nav,
    .et_pb_fullwidth_menu .mobile_nav {
        display: block !important;
    }

    .et_pb_menu .et_mobile_nav_menu,
    .et_pb_fullwidth_menu .et_mobile_nav_menu {
        display: block !important;
        float: none;
    }

    /* Header con Divi Theme Builder: impedisce che il logo si sovrapponga */
    .et_pb_menu_inner_container {
        flex-wrap: wrap;
    }
}

@media only screen and (min-width: 981px) and (max-width: 1260px) {

    /* Allineamento a sinistra e niente puntini */
    .et_pb_menu .et_mobile_menu,
    .et_pb_menu .et_mobile_menu ul,
    .et_pb_menu .et_mobile_menu li,
    .et_pb_menu .et_mobile_menu li a {
        text-align: left !important;
        list-style: none !important;
    }

    /* Azzera il padding ereditato dalle liste del tema */
    .et_pb_menu .et_mobile_menu ul {
        padding: 0 !important;
    }

    /* Posizione e spaziatura del dropdown come su mobile */
    .et_pb_menu .et_mobile_menu {
        top: 100%;
        padding: 5%;
    }

    /* Voci di primo livello e sottomenu */
    .et_mobile_menu li a {
        display: block;
        padding: 10px 5%;
    }

    .et_mobile_menu li li {
        padding-left: 5%;
    }
}

@media only screen and (max-width: 767px) {

    /* Mostra solo la voce Contatti nel menu mobile (IT + EN) */
    .et_pb_menu .et_mobile_menu li.hidden.menu-item-254523,
    .et_pb_menu .et_mobile_menu li.hidden.menu-item-282311,
    .et_pb_menu .et_mobile_menu li.hidden.menu-item-254523 > a,
    .et_pb_menu .et_mobile_menu li.hidden.menu-item-282311 > a {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        height: auto !important;
    }
}


/* ==========================================================
   WPML Language Switcher - Icona a globo (Divi - ISAAC)
   ========================================================== */

/* 1. Nasconde il testo "IT" della lingua attuale */
.et-menu .wpml-ls-current-language > a > .wpml-ls-native {
  display: none;
}

/* 2. Icona a globo via SVG inline, colore fisso #0d3e65 (stesso del menu) */
.et-menu .wpml-ls-current-language > a::before {
  content: "";
  display: inline-block;
  width: 18px;
  height: 18px;
  vertical-align: middle;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230d3e65' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cline x1='2' y1='12' x2='22' y2='12'/%3E%3Cpath d='M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
}

/* 4. Pulizia spazio del link */
.et-menu .wpml-ls-current-language > a { padding-left: 0; }

/* 5. Sottomenu con le altre lingue */
.et-menu .wpml-ls-current-language .sub-menu a {
  display: block;
  white-space: nowrap;
}

.et-menu .wpml-ls-current-language .sub-menu .wpml-ls-native {
  font-size: 14px;
}

/* 6. Stessa cosa per il menu mobile di Divi */
.et_mobile_menu .wpml-ls-current-language > a > .wpml-ls-native {
  display: none;
}

.et_mobile_menu .wpml-ls-current-language > a::before {
  content: "";
  display: inline-block;
  width: 18px;
  height: 18px;
  margin-right: 6px;
  vertical-align: middle;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230d3e65' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cline x1='2' y1='12' x2='22' y2='12'/%3E%3Cpath d='M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
}

/* ==========================================================
   Icona globo - variante bianca per header sticky
   ========================================================== */

/* Versione blu di default (stato normale, sfondo chiaro) */
.et-menu .wpml-ls-current-language > a::before {
  content: "";
  display: inline-block;
  width: 18px;
  height: 18px;
  vertical-align: middle;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230d3e65' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cline x1='2' y1='12' x2='22' y2='12'/%3E%3Cpath d='M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  transition: background-image 0.2s ease;
}

/* Versione bianca quando l'header è sticky */
.et_pb_sticky .et-menu .wpml-ls-current-language > a::before, .home .et-menu .wpml-ls-current-language > a::before {
  background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cline x1='2' y1='12' x2='22' y2='12'/%3E%3Cpath d='M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z'/%3E%3C/svg%3E");
}

/* PROGETTI */ 

#progetti-isaac .difl_cptfilter_0 .df-cpt-inner-wrap {
    padding-top: 0 !important;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: 300px;
}

/* FIX TESTI */
.et_pb_number_counter.et_pb_with_title .percent { margin-bottom: 0 !important; }

@media only screen and (max-width: 767px) {
  .df_timeline_container.layout_left .df_timeline_content_area .df_timeline_content {
    margin-left: 35px;
  }
}

/* Blur Title Vertical Align */
/* Media query for devices with a minimum width of 767 pixels */
@media (max-width: 767px) {
    .vertical-align-blurb .et_pb_blurb_content {
    display: flex;
    flex-direction: row;
    align-items: center;
    max-width: 100%;
}

.vertical-align-blurb .et_pb_main_blurb_image {
    flex: 0 0 auto;
    margin-bottom: 0;
}

.vertical-align-blurb .et_pb_blurb_container {
    flex: 1 1 auto;
    padding-left: 40px;
}

.vertical-align-blurb .et_pb_blurb_description p {
    margin: 0;
    padding-bottom: 0;
}
}

/* TITLE BOX */
.title-box {
  align-items: center;
}

@media (max-width: 980px) {
  .title-box {
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    min-height: 60vh;
  }
}

