/* TIGRA – Duurzame Inzetbaarheid Scan: homepageblok + pop-up
   Alle klassen beginnen met .tdi- zodat ze niet botsen met het thema.
   Het lettertype wordt overgenomen van het thema (font-family: inherit). */

.tdi-blok,
.tdi-popup {
  --tdi-paars: #8F406D;
  --tdi-aubergine: #1C0F47;
  --tdi-groen: #3B7F6C;
  --tdi-groen-donker: #2F6857;
  --tdi-tekst: #3B3155;
  --tdi-grijs: #5A5070;
  --tdi-band: #F6EEF3;
  font-family: inherit;
  color: var(--tdi-aubergine);
}
.tdi-blok *,
.tdi-popup * { box-sizing: border-box; }

/* ---------- Gedeelde onderdelen ---------- */

.tdi-acties {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 28px;
}
.tdi-knop {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 0 30px;
  border-radius: 8px;
  background: var(--tdi-groen);
  color: #fff !important;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none !important;
  transition: background-color .15s ease;
}
.tdi-knop:hover { background: var(--tdi-groen-donker); }
.tdi-link {
  color: var(--tdi-paars) !important;
  font-size: 16px;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.tdi-blok a:focus-visible,
.tdi-blok button:focus-visible,
.tdi-popup a:focus-visible,
.tdi-popup button:focus-visible {
  outline: 3px solid var(--tdi-paars);
  outline-offset: 3px;
}

/* ---------- Homepageblok ---------- */

.tdi-blok {
  background: var(--tdi-band);
  padding: clamp(56px, 8vw, 104px) 24px;
}
.tdi-blok__inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 5fr 6fr;
  gap: 80px;
  align-items: center;
}
.tdi-label {
  display: inline-block;
  margin: 0 0 28px;
  padding: 7px 14px;
  border-radius: 999px;
  background: var(--tdi-paars);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
}
.tdi-blok__titel {
  margin: 0 0 14px;
  color: var(--tdi-aubergine);
  font-size: clamp(32px, 3.4vw, 48px);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -.01em;
}
.tdi-blok__sub {
  margin: 0 0 28px;
  color: var(--tdi-paars);
  font-size: clamp(19px, 1.7vw, 24px);
  font-weight: 500;
  line-height: 1.3;
}
.tdi-blok__intro {
  max-width: 34em;
  margin: 0 0 28px;
  color: var(--tdi-tekst);
  font-size: clamp(16px, 1.25vw, 18px);
  line-height: 1.6;
}
.tdi-checks {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
  margin: 0 0 36px;
  padding: 0;
  list-style: none;
  font-size: 16px;
  font-weight: 500;
}
.tdi-checks li {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0;
}
.tdi-checks li::before {
  content: "";
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%233B7F6C' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") no-repeat center / contain;
}

/* Video / afbeelding */
.tdi-video {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 20px;
  background: #fff;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(28, 15, 71, .14);
  cursor: pointer;
}
.tdi-video--statisch { cursor: auto; }
.tdi-video img {
  position: absolute;
  top: 24px;
  left: 24px;
  width: calc(100% - 48px);
  height: calc(100% - 48px);
  object-fit: contain;
}
.tdi-play {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: var(--tdi-aubergine) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23ffffff'%3E%3Cpath d='M8 5.5v13l10.5-6.5z'/%3E%3C/svg%3E") no-repeat 55% 50% / 32px;
  box-shadow: 0 0 0 10px rgba(255, 255, 255, .7);
  transform: translate(-50%, -50%);
  transition: transform .2s ease;
}
.tdi-video:hover .tdi-play { transform: translate(-50%, -50%) scale(1.06); }
.tdi-video--speelt { aspect-ratio: 16 / 9; background: #000; cursor: auto; }
.tdi-video--speelt.tdi-video--staand { aspect-ratio: 4 / 5; }
.tdi-video__speler {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: #000;
}
.tdi-video__onderschrift {
  margin: 14px 0 0;
  color: var(--tdi-grijs);
  font-size: 15px;
}

@media (max-width: 960px) {
  .tdi-blok__inner { grid-template-columns: 1fr; gap: 40px; }
}
@media (max-width: 640px) {
  .tdi-label { margin-bottom: 22px; font-size: 13px; }
  .tdi-checks { flex-direction: column; gap: 8px; margin-bottom: 28px; font-size: 15px; }
  .tdi-blok .tdi-acties { flex-direction: column; align-items: stretch; text-align: center; }
  .tdi-blok .tdi-knop { width: 100%; min-height: 54px; font-size: 17px; }
  .tdi-video { border-radius: 16px; }
  .tdi-video img { top: 14px; left: 14px; width: calc(100% - 28px); height: calc(100% - 28px); }
  .tdi-play { width: 64px; height: 64px; background-size: 24px; box-shadow: 0 0 0 8px rgba(255, 255, 255, .7); }
}

/* ---------- Pop-up (desktop) ---------- */

html.tdi-no-scroll { overflow: hidden; }

.tdi-popup {
  position: fixed;
  inset: 0;
  z-index: 99990;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.tdi-popup[hidden] { display: none; }
.tdi-popup__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(28, 15, 71, .62);
  opacity: 0;
  transition: opacity .25s ease;
}
.tdi-popup__venster {
  position: relative;
  width: 100%;
  max-width: 560px;
  max-height: calc(100vh - 48px);
  overflow: auto;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .35);
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .25s ease, transform .25s ease;
}
.tdi-popup__venster:focus { outline: none; }
.tdi-popup.is-open .tdi-popup__backdrop { opacity: 1; }
.tdi-popup.is-open .tdi-popup__venster { opacity: 1; transform: none; }

.tdi-popup__beeld {
  aspect-ratio: 560 / 330;
  background: #ACC0D9;
}
.tdi-popup__beeld img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.tdi-popup__sluit {
  position: absolute;
  top: 16px;
  right: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: #fff;
  color: var(--tdi-aubergine);
  box-shadow: 0 4px 14px rgba(0, 0, 0, .15);
  cursor: pointer;
}
.tdi-popup__inhoud { padding: 32px 40px 36px; }
.tdi-popup__meta {
  margin: 0 0 16px;
  color: var(--tdi-paars);
  font-size: 15px;
  font-weight: 600;
}
.tdi-popup__titel {
  margin: 0 0 16px;
  color: var(--tdi-aubergine);
  font-size: 32px;
  font-weight: 800;
  line-height: 1.12;
}
.tdi-popup__tekst {
  margin: 0 0 24px;
  color: var(--tdi-tekst);
  font-size: 17px;
  line-height: 1.55;
}
.tdi-popup .tdi-knop { min-height: 54px; padding: 0 28px; font-size: 17px; }
.tdi-later {
  min-height: 44px;
  padding: 0 4px;
  border: 0;
  background: none;
  color: var(--tdi-grijs);
  font: inherit;
  font-size: 16px;
  font-weight: 500;
  text-decoration: underline;
  cursor: pointer;
}
.tdi-alleen-mobiel { display: none; }

@media (max-height: 720px) and (min-width: 641px) {
  .tdi-popup__beeld { aspect-ratio: 560 / 220; }
}

/* ---------- Pop-up (mobiel: slide-in onderaan, geen overlay) ---------- */

@media (max-width: 640px) {
  .tdi-popup {
    inset: auto 12px 16px 12px;
    display: block;
    padding: 0;
  }
  .tdi-popup__backdrop { display: none; }
  .tdi-popup__venster {
    display: grid;
    grid-template-columns: 92px 1fr;
    grid-template-areas:
      "beeld titel"
      "beeld tekst"
      "acties acties";
    column-gap: 14px;
    row-gap: 4px;
    max-width: none;
    padding: 18px;
    border-radius: 16px;
    box-shadow: 0 -4px 40px rgba(28, 15, 71, .28);
    transform: translateY(24px);
  }
  .tdi-popup__beeld {
    grid-area: beeld;
    width: 92px;
    height: 72px;
    aspect-ratio: auto;
    border-radius: 10px;
    overflow: hidden;
  }
  .tdi-popup__inhoud { display: contents; }
  .tdi-popup__meta,
  .tdi-later,
  .tdi-alleen-desktop { display: none; }
  .tdi-alleen-mobiel { display: inline; }
  .tdi-popup__titel {
    grid-area: titel;
    margin: 0;
    padding-right: 28px;
    font-size: 18px;
    line-height: 1.2;
  }
  .tdi-popup__tekst {
    grid-area: tekst;
    margin: 0;
    font-size: 14px;
    line-height: 1.45;
  }
  .tdi-popup .tdi-acties { grid-area: acties; margin-top: 10px; }
  .tdi-popup .tdi-knop { width: 100%; min-height: 50px; font-size: 16px; }
  .tdi-popup__sluit {
    top: 6px;
    right: 6px;
    background: transparent;
    box-shadow: none;
    color: var(--tdi-grijs);
  }
}

@media (prefers-reduced-motion: reduce) {
  .tdi-popup__backdrop,
  .tdi-popup__venster,
  .tdi-play,
  .tdi-knop { transition: none; }
}
