.block__formation {
    padding: 3rem 0;
}
.filter__formation-search input,
.filter__formation-selects select {
    border-radius: 10px;
    border: 2px solid var(--color-beige-40);
    padding: 1rem;
    margin-bottom: 1.5rem;

}
.filter__formation-selects select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;

  padding-right: 2.5rem;

  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%236d6e70' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round' fill='none'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: 12px 8px;

  /* X puis Y */
  background-position: calc(100% - 14px) calc(50% + 2px);
}
.filter__formation-search .mots_cles {
    width: 100%;
}
.block__formation::before {
    content: '';
    display: block;
    position: absolute;
    z-index: 1;
    background-color: var(--color-blue-uco-dark);
    top:0;
    left:0;
    width: 100%;
    height: 60%;
    border-radius: 0 0 0 300px;
}
.block__formation::after {
    content: '';
    display: block;
    position: absolute;
    z-index: 0;
    background-color: var(--color-blue-uco);
    bottom:0;
    left:0;
    width: 100%;
    height: 100%;
    border-radius: 0 0 240px 0;
}
.block__formation .bouton__green::after {
    display: none
}
.block__formation .container-xxl {
    z-index: 2;
}
.block__formation h2 {
    color: var(--color-blue-uco-dark);
    font-size: clamp(2rem, 2.5vw, 3rem);
    padding: 1rem 3rem;
}
.block__formation > .container-xxl > span.uco {
    display: block;
    width: fit-content;
    margin: -1.5rem 0 0 2rem;
    border-radius: 20px;
    padding: .5rem 1.25rem;
    color: var(--color-white);
    position: relative;
    font-size: 1.25rem;
}
.block__formation .filter__formation-actions a {
    color: var(--color-blue-uco);

    /* Main text */
    font-family: var(--font-family-base);
    font-size: 1rem;
    font-style: normal;
    font-weight: 400;
}
.block__formation .filter__formation-actions a:hover {
    color: var(--color-blue-small-aa);
}
.block__formation .filter__formation-actions a::after {
    content: '→';
    display: inline-block;
    margin-left: .5rem;
}
.block__formation .field--type-link {
    text-align: center;
    margin-top: 2rem;
}
.filter__formation {
    background-color: var(--color-white);
    width: 75%;
    margin: 0 auto;
    padding: 2rem;
    border-radius: 20px;
}
.filter__formation .form-item-mot-cle,
.filter__formation .form-actions {
    flex-basis: 100%;
}
.filter__formation .js-form-item {
    width: calc(25% - .75rem);
}
.filter__formation .form-actions {
    justify-content: center;
    margin-top: 1.5rem;
    margin-bottom: 0;
}
.filter__formation .form-submit {
    width: fit-content;
    background-color: var(--color-green);
    color: var(--color-blue-uco-dark);
    border: 1px solid var(--color-green);
}
.filter__formation .form-select,
.filter__formation .form-control:not(.btn) {
    padding: 1rem 2.5rem 1rem 1rem;
    border-radius: 10px;
    border: 2px solid var(--color-beige-40);
    line-height: 1;
}

@media(max-width: 1200px) {
    .filter__formation-selects select {
        max-width: 40%;
    }
}
@media(max-width: 1000px) {
    .filter__formation-selects select {
        max-width: 30%;
    }
}
@media(max-width: 767px) {
    .filter__formation-selects select {
        max-width: 100%;
    }
}
/* Fluid brand shapes */
.block__formation::before {
    border-radius: 0 0 0 clamp(5rem, 18vw, 18.75rem);
}
.block__formation::after {
    border-radius: 0 0 clamp(4rem, 15vw, 15rem) 0;
}
.filter__formation {
    width: min(75%, 70rem);
}
@media (max-width: 61.99rem) {
    .filter__formation {
        width: min(90%, 70rem);
    }
}
@media (max-width: 47.99rem) {
    .block__formation {
        padding: clamp(2rem, 8vw, 3rem) 0;
    }
    .block__formation h2 {
        padding: .85rem clamp(1.25rem, 6vw, 2rem);
    }
    .block__formation span {
        margin-left: clamp(.75rem, 4vw, 1.5rem);
        font-size: clamp(1rem, 4.5vw, 1.15rem);
    }
    .filter__formation {
        width: 100%;
        padding: clamp(1rem, 5vw, 1.5rem);
    }
}

/* Formation search composition */
.filter__formation {
  width: min(76%, 72rem);
  padding: clamp(1.25rem, 2.3vw, 1.75rem);
  border-radius: 1.1rem;
}

.filter__formation-search input,
.filter__formation-selects select {
  min-height: 3.45rem;
  margin-bottom: .9rem;
}

.filter__formation-selects {
  display: grid !important;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) minmax(0, 1.15fr) minmax(0, .7fr);
  gap: 1rem;
}

.filter__formation-selects select {
  width: 100%;
  max-width: none !important;
  color: gray
}

.filter__formation-select-wrapper {
  min-width: 0;
}

.filter__formation .visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.block__formation .field--type-link {
  margin-top: .55rem;
  padding-top: .2rem;
}

.filter__formation-actions {
  margin-top: 1.15rem !important;
}

@media (max-width: 61.99rem) {
  .filter__formation {
    width: min(90%, 72rem);
  }

  .filter__formation-selects {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 47.99rem) {
  .filter__formation {
    width: 100%;
  }

  .filter__formation-selects {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 47.99rem) {
  .block__formation {
    padding-block: 2.25rem 2.75rem;
  }

  .block__formation h2 {
    padding: .65rem 1.15rem;
    font-size: clamp(1.7rem, 8vw, 2.2rem);
    line-height: 1.02;
  }

  .block__formation span {
    margin-top: -.65rem;
    margin-left: .85rem;
    padding: .35rem .8rem;
    font-size: .9rem;
  }

  .filter__formation {
    width: calc(100% - 1.5rem);
    margin-inline: .75rem;
    padding: 1rem;
    border-radius: 1rem;
  }

  .filter__formation-search input,
  .filter__formation-selects select,
  .filter__formation .form-select,
  .filter__formation .form-control:not(.btn) {
    min-height: 3rem;
    margin-bottom: .65rem;
    padding-block: .7rem;
  }

  .filter__formation-selects {
    gap: .65rem;
  }

  .block__formation .field--type-link,
  .filter__formation-actions {
    margin-top: .75rem !important;
  }
}

@media (max-width: 35.99rem) {
    .block__formation {
        clear: both;
        margin-top: 0;
    }

    .block__formation .container-xxl {
        padding-top: 2rem !important;
    }

    .block__formation h2 {
        position: relative;
        z-index: 2;
        margin-top: 0;
    }
}

/* ==========================================
   ACCUEIL - ALIGNEMENT TITRE FORMATIONS
   Desktop / Tablette / Mobile
========================================== */

.block__formation > .container-xxl {
    --formation-layout-width: min(76%, 72rem);
    --formation-subtitle-indent: 2rem;
    --formation-heading-offset:
        calc((100% - var(--formation-layout-width)) / 2);
}

/* Aligner le titre avec le formulaire */
.block__formation > .container-xxl > h2.bg__green {
    margin-left: var(--formation-heading-offset);
    margin-right: 0;
    max-width: calc(100% - var(--formation-heading-offset));
    box-sizing: border-box;
}

/* Garder le sous-titre aligné sous le titre */
.block__formation > .container-xxl > span.uco {
    margin-left: calc(
        var(--formation-heading-offset) +
        var(--formation-subtitle-indent)
    );
    margin-right: 0;
    max-width: calc(
        100% - var(--formation-heading-offset) -
        var(--formation-subtitle-indent)
    );
    box-sizing: border-box;
}

/* Tablette */
@media (max-width: 991.98px) {
    .block__formation > .container-xxl {
        --formation-layout-width: min(90%, 72rem);
    }
}

/* Mobile */
@media (max-width: 767.98px) {
    .block__formation > .container-xxl {
        --formation-layout-width: calc(100% - 1.5rem);
        --formation-subtitle-indent: .85rem;
    }
}
/* Cartes de formations : reprendre la présentation du composant Campus. */
.block__formation .formations .formation-card__inner > .tag {
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    width: fit-content;
    margin: 0;
    padding: .35rem .9rem;
    color: var(--color-blue-uco-dark);
    font-size: .875rem;
    line-height: 1.2;
}

.block__formation .formations .formation-card__title a {
    color: inherit;
    font: inherit;
    text-decoration: none;
}

.block__formation .formations .formation-card__title a:hover,
.block__formation .formations .formation-card__title a:focus-visible {
    text-decoration: underline;
}

.block__formation .formations .formation-card__footer .button__contour {
    font-weight: 700;
}

.block__formation .formations .formation-card__inner a::after {
    content: none;
}

/* ==========================================
   HOMEPAGE - TITRE MOTEUR DE RECHERCHE
   Chevauchement responsive sans collision
========================================== */

@media (max-width: 991.98px) {

  /* Bandeau turquoise */
  .pageAccueil .block__formation
  > .container-xxl > h2.bg__green {
    position: relative;
    z-index: 1;

    width: fit-content;
    max-width: calc(100% - var(--formation-heading-offset));

    height: auto;
    margin-top: 0;
    margin-bottom: 0;

    padding: .65rem 1.15rem 1.4rem;

    font-size: clamp(1.5rem, 4.7vw, 1.85rem);
    line-height: 1.2;

    white-space: normal;
    overflow-wrap: break-word;
  }

  /* Sous-titre bleu : DEVANT le turquoise */
  .pageAccueil .block__formation
  > .container-xxl > span.uco {
    display: block;
    position: relative;
    z-index: 3;

    width: fit-content;
    max-width: calc(
      100% - var(--formation-heading-offset)
      - var(--formation-subtitle-indent)
    );

    /* Chevauchement volontaire */
    margin-top: -.8rem;
    margin-left: calc(
      var(--formation-heading-offset)
      + var(--formation-subtitle-indent)
    );
    margin-bottom: 0;

    padding: .4rem .85rem;

    background-color: var(--color-blue-uco);
    color: var(--color-white);

    border-radius: 20px;

    font-size: clamp(.8rem, 2.5vw, .95rem);
    line-height: 1.35;

    height: auto;
    white-space: normal;
    overflow-wrap: break-word;
  }
}