/* ==========================================================================
   NavigatieInbouwen.nl, laag 3: dienstensectie + info-popup
   Overgenomen van de sectie "Onze services" op navicenter.nl, maar dan
   gebouwd op de tokens van dit theme (donkere pagina, gele kaarten) en
   met een informatie-popup in plaats van een aanvraagformulier.
   Laadt alleen waar de sectie/shortcode staat (zie inc/services.php).
   ========================================================================== */

/* ---------- Sectie ---------- */
.services {
  padding: clamp(70px, 9vw, 110px) 0;
  background: var(--black);
}
.services__head { text-align: center; max-width: 640px; margin: 0 auto clamp(34px, 4.6vw, 54px); }
.services__head .section-sub { margin-left: auto; margin-right: auto; }

.services__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
@media (max-width: 960px) { .services__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; } }
@media (max-width: 620px) { .services__grid { grid-template-columns: 1fr; } }

/* ---------- Kaart ---------- */
.svc-card {
  display: flex; flex-direction: column; align-items: center; justify-content: flex-start;
  gap: 14px;
  width: 100%; margin: 0;
  text-align: center;
  background: var(--yellow);
  border: 1px solid var(--yellow);
  border-radius: var(--radius-lg);
  padding: clamp(28px, 3vw, 34px) 22px;
  color: var(--black);
  font-family: var(--font-body);
  font-size: 15px; font-weight: 400; line-height: 1.55;
  transition: background 0.22s var(--ease), border-color 0.22s var(--ease),
              box-shadow 0.22s var(--ease), transform 0.22s var(--ease);
}
.svc-card:hover, .svc-card:focus-visible {
  background: var(--yellow-deep);
  border-color: var(--yellow-deep);
  box-shadow: 0 16px 38px rgba(254, 190, 20, 0.22);
  transform: translateY(-3px);
}

.svc-card__icon { display: flex; align-items: center; justify-content: center; height: 38px; color: var(--white); }
.svc-card__icon svg { transition: transform 0.22s var(--ease); }
.svc-card:hover .svc-card__icon svg { transform: scale(1.06); }

.svc-card__body { display: block; min-width: 0; flex: 1 1 auto; }
.svc-card__title {
  display: block; margin-bottom: 8px;
  font-family: var(--font-head);
  font-size: clamp(16px, 1.8vw, 18px); font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.02em; line-height: 1.25;
  color: var(--black);
}
.svc-card__text { display: block; font-size: 14px; line-height: 1.6; color: rgba(0, 0, 0, 0.72); }

.svc-card__cta {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 2px; padding-bottom: 3px;
  font-size: 13.5px; font-weight: 600; color: var(--black);
  border-bottom: 1px solid rgba(0, 0, 0, 0.45);
}
.svc-card__cta svg { transition: transform 0.22s var(--ease); }
.svc-card:hover .svc-card__cta { border-bottom-color: var(--black); }
.svc-card:hover .svc-card__cta svg { transform: translateX(3px); }

/* ---------- Popup ---------- */
.svc-modal {
  position: fixed; inset: 0; z-index: 99999;
  display: none; align-items: flex-end; justify-content: center;
  font-family: var(--font-body);
}
.svc-modal.is-open { display: flex; }
@media (min-width: 640px) { .svc-modal { align-items: center; } }

.svc-modal__overlay {
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(4px);
  animation: svc-fade 0.2s var(--ease);
}
.svc-modal__dialog {
  position: relative; z-index: 1;
  display: flex; flex-direction: column; overflow: hidden;
  width: 100%; max-width: 620px; max-height: 92vh;
  background: linear-gradient(145deg, var(--dark-2) 0%, var(--dark-3) 100%);
  border: 1px solid var(--line-dark);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  color: var(--white);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.65);
  animation: svc-up 0.28s var(--ease);
}
@media (min-width: 640px) {
  .svc-modal__dialog { width: calc(100% - 40px); max-height: 88vh; border-radius: var(--radius-lg); animation: svc-pop 0.24s var(--ease); }
}
@keyframes svc-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes svc-up { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: none; } }
@keyframes svc-pop { from { opacity: 0; transform: translateY(12px) scale(0.985); } to { opacity: 1; transform: none; } }

.svc-modal__header {
  position: relative; flex: 0 0 auto;
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  padding: 30px 56px 22px;
  text-align: center;
  border-bottom: 1px solid var(--line-dark);
}
.svc-modal__icon {
  display: grid; place-items: center;
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--yellow); color: var(--white);
}
.svc-modal__title {
  margin: 0;
  font-family: var(--font-head);
  font-size: 19px; font-weight: 700; line-height: 1.25;
  text-transform: uppercase; letter-spacing: 0.02em;
}
.svc-modal__sub { margin: 6px 0 0; font-size: 13.5px; color: var(--grey); line-height: 1.5; }

.svc-modal__close {
  position: absolute; top: 16px; right: 16px;
  display: grid; place-items: center;
  width: 36px; height: 36px; padding: 0;
  border: 1.5px solid var(--line-dark); border-radius: 50%;
  background: var(--black); color: var(--white);
  transition: border-color 0.2s var(--ease), color 0.2s var(--ease);
}
.svc-modal__close:hover, .svc-modal__close:focus-visible { border-color: var(--yellow); color: var(--yellow); }

.svc-modal__body {
  flex: 1 1 auto; overflow-y: auto; -webkit-overflow-scrolling: touch;
  padding: 26px clamp(20px, 4vw, 32px) 30px;
  text-align: left;
}

/* ---------- Inhoud van de popup ---------- */
.svc-info p { margin: 0 0 14px; font-size: 15px; line-height: 1.7; color: var(--grey); }
.svc-info p:last-child { margin-bottom: 0; }
.svc-info strong { color: var(--white); font-weight: 600; }
.svc-info a { color: var(--yellow); text-decoration: underline; }
.svc-info h3, .svc-info h4 {
  margin: 22px 0 10px;
  font-family: var(--font-head);
  font-size: 16px; font-weight: 700; color: var(--white);
}
.svc-info ul, .svc-info ol { display: grid; gap: 10px; margin: 0 0 18px; padding: 0; }
.svc-info ul li {
  position: relative;
  padding-left: 30px;
  font-size: 14.5px; line-height: 1.6; color: var(--grey);
  list-style: none;
}
.svc-info ul li::before {
  content: "";
  position: absolute; left: 0; top: 4px;
  width: 18px; height: 18px; border-radius: 50%;
  background: rgba(35, 164, 85, 0.16);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='none' stroke='%2323a455' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m2 6.5 3 3 5-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: center;
}
.svc-info ol { padding-left: 20px; }
.svc-info ol li { list-style: decimal; font-size: 14.5px; line-height: 1.6; color: var(--grey); }

.svc-modal__facts {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px; margin: 4px 0 20px;
}
.svc-fact {
  padding: 14px 16px;
  background: var(--black);
  border: 1px solid var(--line-dark);
  border-radius: var(--radius);
  text-align: center;
}
.svc-fact strong {
  display: block;
  font-family: var(--font-head);
  font-size: 17px; font-weight: 700; color: var(--yellow);
}
.svc-fact span { display: block; margin-top: 2px; font-size: 12.5px; color: var(--grey); }

.svc-modal__actions {
  display: flex; flex-wrap: wrap; gap: 12px;
  margin-top: 24px; padding-top: 22px;
  border-top: 1px solid var(--line-dark);
}
.svc-modal__actions .btn { flex: 1 1 200px; padding: 15px 24px; font-size: 15px; }

html.svc-modal-open, body.svc-modal-open { overflow: hidden; }
