/* Global Styles */
body {
  font-family: 'Poppins', sans-serif;
  line-height: 1.6;
  margin: 0;
  padding: 0;
  background-color: #f4f4f4;
}

.container {
  width: 80%;
  margin: 0 auto;
  padding: 20px;
  background: #fff;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  border-radius: 8px;
}

h2, h3 {
  color: #333;
  text-align: left;
  font-family: 'Poppins', sans-serif;
}

strong {
  color: var(--heading-color);
  font-family: 'Poppins', sans-serif;
}

/* Formation Section */
.formation_description {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.formation_info {
  padding-bottom: 15px;
}

.formation_card {
  background: #fff;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}
body.dark .formation_card {
  background: var(--nav-color);
  color: var(--text-color);
  box-shadow: 0 0 10px #000;
}

.formation_card p strong {
  display: block;
  margin-bottom: 10px;
  font-size: 1.2em;
}

.formation_card ul, .formation_card ol {
  margin-left: 20px;
}

.formation_card ul li, .formation_card ol li {
  margin-bottom: 10px;
  padding-left: 10px;
  position: relative;
  line-height: 1.6;
  font-size: 1.1em;
}

.formation_card ul li::before, .formation_card ol li::before {
  color: var(--heading-color);
  position: absolute;
  left: 0;
}

.formation_card p a {
  color: #0073e6;
  text-decoration: none;
  transition: color 0.3s ease;
}

.formation_card p a:hover {
  color: #005bb5;
  text-decoration: underline;
}

/* Certificat Section Grid */
.certificat__grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}
.certificat_title {
  padding-bottom: 20px;
}
.certificat__item {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 150px;
  flex: 1 1 calc(33.333% - 20px);
  background: #fff;
  padding: 25px;
  border-radius: 8px;
  text-align: center;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  text-decoration: none;
  color: dodgerblue;
}

.certificat__item:hover {
  transform: translateY(-10px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);  
}

.certificat__item {
  display: none;
}
.certificat__item.default {
  display: flex;
}

.certificat__item:nth-child(-n+8), .certificat__item:nth-child(-n+9) {
  display: flex;
}

body.dark .certificat__item {
  background: var(--nav-color);
  color: var(--text-color);
  box-shadow: 0 0 10px #000;
}

.cta-button {
  display: inline-block;
  padding: 12px 20px;
  background: #0073e6;
  color: #fff;
  text-decoration: none;
  border-radius: 4px;
  transition: background 0.3s ease;
  text-align: center;
  margin-top: 20px;
  cursor: pointer;
}

.cta-button:hover {
  background: #005bb5;
}

body.dark .cta-button {
  background: #0073e6;
  box-shadow: 0 0 10px #000;
}

body.dark .cta-button:hover {
  background: #005bb5;
}
/* Responsive styles */
@media (max-width: 790px) {
  .formation_title {
    text-align: center;
    padding-bottom: 15px;
  }
  .formation_info {
    font-style: italic;
    font-size: 12px;
  }
  .certificat_title {
    padding-bottom: 15px;
  }
  .section.formation, .section.certificat {
    margin-top: 36px;
  }
  .certificat__item.default:nth-child(n+9) {
    display: none;
  }
  .certificat__item.default:nth-child(-n+8) {
    display: flex;
  }
  .certificat__item {
    flex: 1 1 calc(50% - 20px); /* 2 items per row */
}
}
@media (min-width: 791px) {
  .certificat__item.default:nth-child(n+10) {
    display: none;
  }
  .certificat__item.default:nth-child(-n+9) {
    display: flex;
  }
}
