/*
 Theme Name:   OceanWP Child
 Theme URI:    https://oceanwp.org/
 Description:  Thème enfant pour OceanWP
 Author:       Alexis
 Author URI:   https://tonsite.fr
 Template:     oceanwp
 Version:      1.0
*/

/* Importe les styles du parent */
@import url("../oceanwp/assets/css/style.css");

html, body {
  height: 100%;
  margin: 0;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh; /* Hauteur minimum = taille de la fenêtre */
}

main {
  flex: 1; /* Prend tout l'espace restant pour pousser le footer en bas */
}

footer {
  background: #333;
  color: white;
  text-align: center;
  padding: 15px;
}

/* Grille responsive */
.formations-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3rem;
  margin-top: 2rem;
}

@media (max-width: 1024px) {
  .formations-grid {
    grid-template-columns: repeat(2, 1fr);
    justify-items: center;
  }
}

@media (max-width: 770px) {
  .formations-grid {
    grid-template-columns: 1fr;
    justify-items: center;
  }
}

.loader {
    text-align: center;
    margin: 20px 0;
}

.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #FF681D;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.formations-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
  margin: 2rem auto;
  justify-content: center;
  font-weight: 400;
}

.chip-filter {
  border: none;
  background: #eee;
  padding: 8px 14px;
  border-radius: 20px;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.3s ease;
}

.chip-filter.active {
  background-color: #FF681D;
  color: white;
}

.formation-card {
  border: 1px solid #e6ecf1;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 0 0 1px #edf2f7;
  max-width: 1200px;
  background-color: #fff;
  display: flex;
  flex-direction: column;

  &.trend{
    flex-direction: unset;
    padding: 24px;
  }
}

.formation-image {
  width: 100%;
  height: 220px !important ;
  object-fit: cover;
}
.formation-image-trend {
  width: 100%;
  height: 330px;
  object-fit: cover;
  overflow: hidden;
  border-radius: 8px;
}

.formation-content {
  padding: 20px;

  &.trend{
    padding: 16px 16px;
    max-width: 430px;
  }
}

.formation-level {
  background-color: #FF681D;
  color: white;
  font-weight: 600;
  font-size: 14px;
  padding: 6px 12px;
  border-radius: 6px;
  display: inline-block;
  margin-bottom: 12px;
}

.formation-meta {
  display: flex;
  gap: 16px;
  font-size: 13px;
  font-weight: 500;
  color: #4b5563;
  margin-bottom: 10px;
}

.formation-meta i {
  color: #3b82f6;
  margin-right: 6px;
}

.formation-title {
  font-size: 25px;
  font-weight: 600;
  color: #1e293b;
  margin-bottom: 8px;
}

.formation-description {
  font-size: 13px;
  font-weight: 500;
  color: #6b7280;
  line-height: 1.5;
  margin-bottom: 16px;
  height: 60px;
  overflow : hidden;
  text-overflow :    ellipsis;

  &.trend{
    margin-bottom: 4px;
    height: 40px;
  }
}

.formation-button {
  border: 2px solid #FF681D;
  background-color: white;
  color: #FF681D;
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
  border-radius: 30px;
  padding: 5px 10px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.3s ease;

  &.center{
    margin: 2rem auto;
    display: flex;

  }

  &.invert{
    color: white; 
    background-color: #FF681D; 
    padding: 5px 10px; 
  }
}

.formation-button:hover {
  background-color: #FF681D;
  border: 2px solid #FF681D;
  color: white;
}

.invert:hover {
  background-color: white;
  border: 2px solid #FF681D;
  color: #FF681D;
}

.anchor-menu {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  background-color: #FF681D;
  padding: 1rem;
  border-radius: 10px;
  margin-bottom: 2rem;
}
.anchor-menu a {
  color: white;
  font-weight: bold;
  text-decoration: none;
  padding: 0.5rem 1rem;
  border-radius: 25px;
}
.anchor-menu a:hover {
  color: black;

}
.anchor-menu a.active {
  background: white;
  color: #FF681D;
}
.anchor-menu .separator {
  color: white;
  font-weight: bold;
}

.underline {
  width: 60px;
  height: 4px;
  background: #FF681D;
  margin-bottom: 3rem;
}

.accordion-title {
  background-color: white;
  padding: 1rem;
  cursor: pointer;
  font-weight: 500;
  font-size: large;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: none;
  width: 100%;
  opacity: 0.8;
}

.accordion-content {
  max-height: 0;
  overflow: hidden;
  padding: 0 1rem; 
  border: 1px solid #eee;
  background-color: #fff;
  transition: max-height 0.4s ease, padding 0.3s ease;
}

.accordion-content.open {
  padding: 1rem; 
}

.formation-programme{
  margin-top: 3rem;
}

.accordion-item{
  margin-top: 2rem;
}

.accordion-block{
  margin: 2rem 0 2rem 0;
}

.accordion-icon {
  font-size: 2rem;
}

.formation-single {
  max-width: 1140px;
  margin: auto;
  padding: 0 16px;
}

.formation-title {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.formation-infos {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2rem;
}

.formation-infos .info-item {
  flex: 1 1 200px;
  display: flex;
  flex-direction: column;
  padding: 1rem;
  border: 1px solid #ccc;
  border-radius: 8px;
  text-align: center;
  align-content: center;
  align-items: center;
}

.formation-infos .icon {
  margin-right: 0.5rem;
}

.formation-presentation {
  display: flex;
  flex-wrap: nowrap;
  gap: 2rem;
  margin-bottom: 2rem;
}

.formation-presentation .text {
  width: 60%;
}

.copyright-text {
  font-size: 14px;
  background-color: #FFF;
  width: 100%;
  text-align: center;
  margin-bottom: 0 !important;
  padding: 1rem 0;
}


.button-group {
  margin-top: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.formation-presentation .image {
  flex: 1 1;
}

.formation-presentation .image img {
  max-width: 100%;
  border-radius: 8px;
}

.formation-price{
    font-weight: bold;
    font-size: 2.5rem;
    color: #FF681D;
}

.price {
  display: inline-block;
  color: #FF681D;
  padding: 0.5rem 1rem;
  font-weight: bold;
}

.formation-infos-cle {
  margin-top: 3rem;
}

.formation-chiffres-cle {
  margin-top: 3rem;
}

.infos-cols {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.infos-cols .col {
  flex: 1 1;
  border-radius: 10px;
}

.infos-cols .prerequis p {
  border: 1px solid #b9161b;
  border-radius: 8px;
  padding: 16px;
}


.infos-cols .profils p {
  border: 1px solid #e3b341;
  border-radius: 8px;
  padding: 16px;
}
.infos-cols .modalites p {
  border: 1px solid #536ad4;
  border-radius: 8px;
  padding: 16px;
}
.infos-cols .objectifs p {
  border: 1px solid #e3b341;
  border-radius: 8px;
  padding: 16px;
}
.infos-cols .organisation div {
  border: 1px solid #536ad4;
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 16px;
}
.infos-cols .points p {
  border: 1px solid #e3b341;
  border-radius: 8px;
  padding: 16px;
}

.infos-cols .col .h3_prerequis {
  margin-top: 0;
  background-color: #b9161b;
  color: white;
  text-align: center;
  margin-bottom: 8px !important;
  padding: 8px;
  border-radius: 8px;
}
.infos-cols .col .h3_profil {
  margin-top: 0;
  background-color: #e3b341;
  color: white;
  text-align: center;
  margin-bottom: 8px !important;
  padding: 8px;
  border-radius: 8px;
}
.infos-cols .col .h3_modalites {
  margin-top: 0;
  background-color: #536ad4;
  color: white;
  text-align: center;
  margin-bottom: 8px !important;
  padding: 8px;
  border-radius: 8px;
}
.infos-cols .col .h3_objectifs {
  margin-top: 0;
  background-color: #e3b341;
  color: white;
  text-align: center;
  margin-bottom: 8px !important;
  padding: 8px;
  border-radius: 8px;
}
.infos-cols .col .h3_organisation {
  margin-top: 0;
  background-color: #536ad4;
  color: white;
  text-align: center;
  margin-bottom: 8px !important;
  padding: 8px;
  border-radius: 8px;
}
.infos-cols .col .h3_points {
  margin-top: 0;
  background-color: #e3b341;
  color: white;
  text-align: center;
  margin-bottom: 8px !important;
  padding: 8px;
  border-radius: 8px;
}

@media (max-width: 768px) {
  .formation-tabs {
    flex-direction: column;
  }

  .infos-cols {
    flex-direction: column;
  }
  .anchor-menu {
    flex-direction: column;
    gap: 0;
  }
  .formation-image-trend{
    height: auto;
  }
}
@media (max-width: 1150px) {
  .formation-presentation {
    flex-direction: column;
  }

  .formation-presentation .text {
    width: 100%;
  }
  .formation-card{
    &.trend{
      display: flex;
      flex-direction: column;
      max-width: 550px;
      margin: auto;
    }
  }
  .formation-image-trend{
    max-width: 550px ;
  }
}
