#toc-widget .blokje, #toc-widget p {
  font-size: 18px;
  line-height: 1.2em;
}

#toc-widget a:hover {
  font-size: 18px;
}

#toc-widget h1, #toc-widget h2, #toc-widget h3, #toc-widget h4 {
  margin: 0 !important;
}

.blokje {
    padding: 1.5rem;
      break-inside: avoid;
  page-break-inside: avoid;
  display: block;
}

#toc-widget ul, #toc-widget li {
  font-size: 18px;
}

#toc-widget ul, #toc-widget ol {
  margin-bottom: 18px;
}

#toc-widget h1 {
  font-size: 42px;
}

#toc-widget section {
  margin: 0;
  display: flex;
  align-items: center;
  min-height: 100px; /* Ensure sections have a minimum height */
  padding: 1rem 0;
}

.titel {
  font-size: 19px !important;
  max-height: 150px;
  white-space: normal !important;
  line-height: 1.4rem;
  width: 60px;
  display: flex;
  justify-content: center;
  align-self: center;
  writing-mode: vertical-rl;
  transform: rotate(-180deg);
  font-weight: bold;
  padding: 10px 1rem 10px 0;
}

.toc-widget .block {
  padding: 1rem;
  border-radius: 1rem;
  font-size: 1rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  flex-grow: 1;
}

.toc-widget .card ul {
  padding-left: 1.25rem;
  margin-top: 0.5rem;
  font-size: 0.95rem;
}

.toc-widget .flex-row {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.section-container {
  min-width: 80px;
  display: flex;
  align-items: center;
}

.content-container {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: calc(100% - 60px);
}

.background-parent {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  grid-template-rows: repeat(2, 1fr);
  grid-column-gap: 1rem;
  grid-row-gap: 1rem;
  width: 100%;
  min-height: 300px;
  margin-top: 1rem;
}

.background-parent .blokje:nth-of-type(1) { grid-area: 1 / 1 / 2 / 2; }
.background-parent .blokje:nth-of-type(2) { grid-area: 2 / 1 / 3 / 2; }
.background-parent .blokje:nth-of-type(3) { grid-area: 1 / 2 / 3 / 3; }
.background-parent .blokje:nth-of-type(4) { grid-area: 1 / 3 / 3 / 6; }

/* einddoel */

.section-endgoal .blokje {
  font-size: 28px !important;
  line-height: 1.2em !important;
  font-weight: 600;
}

.section-endgoal > div:not(.titel) {
  display: flex;
  flex-direction: row !important;
  flex-wrap: wrap;
}

/* SDG's*/

.sdg-icon img {
  max-width: 80px;
  border-radius: 10px;
}

.sdg-icon {
  display: grid !important;
  gap: .5rem !important;
}

.sdg-count-2 {
  width: 80px;
  grid-template-columns: 1fr;
}

.sdg-count-3 {
  width: calc(160px + 1rem);
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto auto;
}

.sdg-count-4 {
  width: calc(160px + 1rem);
  grid-template-columns: 1fr 1fr;
}

.background-parent {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  grid-template-rows: repeat(2, 1fr);
  grid-column-gap: 1rem;
  grid-row-gap: 1rem;
  width: 100%;
  min-height: 300px;
}

/* hr en pijltje */

.section-divider {
  margin-top: -20px;
  height: 60px;
  text-align: center;
}

.section-divider img {
  margin-left: 90px;
  height: 50px;
}

.hr-en-pijltje hr {
  width: 100% !important;
  max-width: 100% !important;
  margin-top: -8px;
  border: none;
  height: 5px;
  background-image: linear-gradient(to right, #333 33%, transparent 0%);
  background-position: bottom;
  background-size: 20px 2.5px;
  background-repeat: repeat-x;
}

.hr-en-pijltje img {
  margin-left: 90px;
  height: 50px;
}

.section-input .blokje {
  text-align: center;
  align-items: center;
  display: flex;
  justify-content: center;
  flex-direction: column;
}
.section-outcomes .blokje {
  font-size: 18px;
  text-align: center;
  align-items: center;
  justify-content: center;
}

/* Enablers */

.section-enablers .flex-row {
  justify-content: center;
  row-gap: 4rem !important;
}

.section-enablers .blokje:nth-of-type(even) {
  margin-top: -40px;
}
.section-enablers .blokje:nth-of-type(odd) {
  margin-bottom: -40px;
}

.section-enablers .blokje {
  aspect-ratio: 1/1 !important;
  width: 150px;
  max-width: 150px;
  border-radius: 50% !important;
  text-align: center;
  align-items: center;
  display: flex;
  justify-content: center;
  flex-direction: column;
}

/* activiteiten */

#toc-widget .section-activities .blokje h3 {
  font-size: 20px;
  margin-top: 0;
  margin-bottom: 20px !important;
}

.section-activities {
  margin-bottom: 20px !important;
}

/* input */

.section-input {
  padding-top: 0px !important;
}

/* extra sections */

#toc-widget .page-2 h3 {
  font-size: 26px;
  margin: 20px 0 18px 0 !important;
}
.page-2 p {
  font-size: 20px;
}
.page-2 {
  padding: 12px 40px 30px 40px;
  margin-bottom: 30px;
}

/* Achtergrond */

.section-background {
  flex-wrap: wrap;
}

.section-background .section-container {
  width: 100% !important;
}

#toc-widget .section-background .section-container h3.titel {
  padding: 0 !important;
  writing-mode: horizontal-tb;
  margin: 40px 0 20px 80px !important;
  height: 20px;
  width: 100% !important;
  display: block;
  text-align: center;
  transform: rotate(0deg) !important;
}

#toc-widget .section-background .content-container .blokje h3 {
  margin-bottom: 18px !important;
}

.section-background .blokje {
  min-width: 250px;
}
.section-background .blokje:first-of-type {
  border: 4px solid var(--endgoal-bg);
}

.section-background {
  margin-bottom: 80px !important;
}

/* Responsive breakpoints */

/* For tablets and smaller (1000px and below) */
@media screen and (max-width: 1000px) {
  .background-parent {
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
  }
  
  .background-parent .blokje {
    grid-area: auto !important;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  
  /* Reset specific grid areas for 2x2 layout */
  .background-parent .blokje:nth-of-type(1) { grid-area: 1 / 1 / 2 / 2; }
  .background-parent .blokje:nth-of-type(2) { grid-area: 2 / 1 / 3 / 2; }
  .background-parent .blokje:nth-of-type(3) { grid-area: 1 / 2 / 2 / 3; }
  .background-parent .blokje:nth-of-type(4) { grid-area: 2 / 2 / 3 / 3; }
}

/* For mobile (769px and below) */
@media screen and (max-width: 769px) {
  section, .branding {
    width: 100%;
    flex-direction: column !important;
    flex-wrap: wrap !important;
  }
  
  .background-parent {
    grid-template-columns: 1fr !important;
    grid-template-rows: auto !important;
  }
  
  .background-parent .blokje {
    grid-area: auto !important;
    width: 100%;
    max-width: 100%;
    margin-bottom: 1rem;
  }
.section-endgoal > div:not(.titel) {
  display: flex;
  flex-direction: column !important;
  flex-wrap: wrap;
}
.titel {
  writing-mode: vertical-rl;
  height: auto;
  transform: rotate(-90deg) !important;
}
.sdg-icon {
  grid-template-columns: 1fr 1fr 1fr 1fr;
}
.section-divider img {
  margin-left: 0px;
  height: 50px;
  margin-top: 20px;
}
.hr-en-pijltje img, #toc-widget .section-background .section-container h3.titel {
  margin-left: 0px !important;
}
.footer div {
  flex: 0 1 100% !important;
}
}

@media print {
  .blokje {
    break-inside: avoid;
    page-break-inside: avoid;
    display: block;
  }
}