/*
Theme Name: Watpastbijmij Child
Template: generatepress
Description: Child theme voor Watpastbijmij.nl. Bevat het centrale design system.
Version: 1.0.0
Author: Watpastbijmij.nl
*/

/* ===== 1. DESIGN TOKENS ===== */
/* Kleuren beheer je in Customizer > Kleuren. Ze werken hier automatisch door. */
:root {
  --wpbm-space-xs: 0.5rem;
  --wpbm-space-sm: 1rem;
  --wpbm-space-md: 1.5rem;
  --wpbm-space-lg: 2rem;
  --wpbm-space-xl: 3rem;
  --wpbm-space-2xl: 4rem;
  --wpbm-space-3xl: 6rem;
  --wpbm-radius-sm: 8px;
  --wpbm-radius-md: 12px;
  --wpbm-radius-lg: 16px;
  --wpbm-radius-pill: 999px;
  --wpbm-shadow-sm: 0 1px 3px rgba(13, 27, 61, 0.06);
  --wpbm-shadow-md: 0 4px 14px rgba(13, 27, 61, 0.08);
  --wpbm-shadow-lg: 0 10px 30px rgba(13, 27, 61, 0.12);
  --wpbm-tekst-zacht: #5b6478;
  --wpbm-border: 1px solid #e8ecf3;
}

/* ===== 2. SECTIES ===== */
.wpbm-section { padding-block: var(--wpbm-space-3xl); }
.wpbm-section--licht { background-color: var(--base-2); }
.wpbm-section--wit { background-color: var(--base-3); }
.wpbm-section--donker { background-color: var(--contrast); color: var(--base-3); }
.wpbm-section--donker h1,
.wpbm-section--donker h2,
.wpbm-section--donker h3 { color: var(--base-3); }

.wpbm-section > .wp-block-group__inner-container {
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: var(--wpbm-space-lg);
}

/* Volledige breedte: secties lopen randloos door */
.full-width-content .site.grid-container { max-width: 100%; padding-inline: 0; }
.full-width-content .inside-article,
.full-width-content .entry-content { padding: 0; }
.full-width-content .entry-content > *:first-child { margin-block-start: 0; }

/* ===== 3. BUTTONS ===== */
/* De klasse staat op de wrapper; we stylen de link erbinnen. */
.wpbm-btn-primair > .wp-block-button__link,
.wpbm-btn-secundair > .wp-block-button__link,
.wpbm-btn-accent > .wp-block-button__link,
a.wpbm-btn-primair,
a.wpbm-btn-secundair,
a.wpbm-btn-accent {
  display: inline-flex;
  align-items: center;
  gap: var(--wpbm-space-xs);
  padding: 0.85rem 1.75rem;
  border-radius: var(--wpbm-radius-sm);
  font-weight: 600;
  font-size: 16px;
  line-height: 1.2;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.wpbm-btn-primair > .wp-block-button__link,
a.wpbm-btn-primair {
  background-color: var(--contrast);
  color: var(--base-3);
  border: 1px solid var(--contrast);
}
.wpbm-btn-primair > .wp-block-button__link:hover,
a.wpbm-btn-primair:hover {
  background-color: var(--accent);
  border-color: var(--accent);
  color: var(--base-3);
}

.wpbm-btn-secundair > .wp-block-button__link,
a.wpbm-btn-secundair {
  background-color: var(--base-3);
  color: var(--contrast);
  border: 1px solid var(--contrast);
}
.wpbm-btn-secundair > .wp-block-button__link:hover,
a.wpbm-btn-secundair:hover {
  background-color: var(--contrast);
  color: var(--base-3);
}

.wpbm-btn-accent > .wp-block-button__link,
a.wpbm-btn-accent {
  background-color: var(--accent);
  color: var(--base-3);
  border: 1px solid var(--accent);
}
.wpbm-btn-accent > .wp-block-button__link:hover,
a.wpbm-btn-accent:hover {
  background-color: var(--contrast);
  border-color: var(--contrast);
  color: var(--base-3);
}

.wpbm-tekstlink { color: var(--accent); font-weight: 600; text-decoration: none; }
.wpbm-tekstlink:hover { text-decoration: underline; }

/* ===== 4. CARDS ===== */
.wpbm-card {
  background-color: var(--base-3);
  border: var(--wpbm-border);
  border-radius: var(--wpbm-radius-lg);
  box-shadow: var(--wpbm-shadow-sm);
  padding: var(--wpbm-space-md);
}
.wpbm-card--hover { transition: box-shadow 0.18s ease, transform 0.18s ease; }
.wpbm-card--hover:hover { box-shadow: var(--wpbm-shadow-md); transform: translateY(-3px); }
.wpbm-card--uitgelicht { border-color: var(--accent); box-shadow: var(--wpbm-shadow-md); }

.wpbm-badge {
  display: inline-block;
  background-color: var(--accent);
  color: var(--base-3);
  font-size: 13px;
  font-weight: 600;
  padding: 0.25rem 0.75rem;
  border-radius: var(--wpbm-radius-pill);
}

/* ===== 5. BREADCRUMBS ===== */
.wpbm-breadcrumbs { padding-block: var(--wpbm-space-sm); font-size: 14px; color: var(--contrast); }
.wpbm-breadcrumbs a { color: var(--contrast); text-decoration: none; opacity: 0.7; }
.wpbm-breadcrumbs a:hover { opacity: 1; }
.wpbm-breadcrumbs .separator { opacity: 0.45; margin-inline: 0.4rem; }

/* ===== 6. HEADER & FOOTER ===== */
.site-header { border-bottom: var(--wpbm-border); }
.site-footer .footer-widgets .widget-title { font-weight: 600; }
.site-footer .footer-widgets a { text-decoration: none; }
.site-info { border-top: 1px solid rgba(255, 255, 255, 0.12); }
.site-info a { text-decoration: none; }

.wpbm-footer-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--wpbm-space-md);
  font-size: 14px;
}

/* ===== 7. TOEGANKELIJKHEID ===== */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ===== 8. HERO ===== */
.wpbm-hero { background-color: var(--base-2); overflow: hidden; padding-block: 0; }
.wpbm-hero > .wp-block-group__inner-container { padding-bottom: 0; }
.wpbm-hero .wp-block-columns { align-items: flex-end !important; gap: var(--wpbm-space-xl); margin-bottom: 0; }

.wpbm-hero-tekst { padding-block: var(--wpbm-space-3xl); }
.wpbm-hero h1 { margin-bottom: var(--wpbm-space-md); max-width: 13ch; }
.wpbm-hero-intro {
  font-size: 19px;
  line-height: 1.6;
  max-width: 32ch;
  margin-bottom: var(--wpbm-space-lg);
}

.wpbm-hero-media { position: relative; align-self: flex-end !important; }
.wpbm-hero-media figure { margin: 0; }
.wpbm-hero-media img { display: block; width: 100%; height: auto; }

.wpbm-hero-badge {
  position: absolute;
  right: -1rem;
  bottom: 22%;
  z-index: 2;
  background: var(--base-3);
  border-radius: var(--wpbm-radius-md);
  box-shadow: var(--wpbm-shadow-lg);
  padding: var(--wpbm-space-sm) var(--wpbm-space-md);
  max-width: 15rem;
}
.wpbm-hero-badge p { margin: 0; font-size: 14px; line-height: 1.5; color: var(--wpbm-tekst-zacht); }
.wpbm-hero-badge .wpbm-badge-titel {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  font-size: 15px;
  color: var(--contrast);
  margin-bottom: 0.45rem;
}
.wpbm-hero-badge .wpbm-badge-titel::before {
  content: "";
  flex: 0 0 auto;
  width: 1.2rem;
  height: 1.2rem;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2316C1A5' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 2 4 5v6c0 5 3.4 8.2 8 9.5 4.6-1.3 8-4.5 8-9.5V5l-8-3Z'/%3E%3Cpath d='m9 12 2 2 4-4'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* ===== 9. CHECKLIST ===== */
.wpbm-checklist { list-style: none; padding-left: 0; margin: 0 0 var(--wpbm-space-lg); }
.wpbm-checklist li {
  position: relative;
  padding-left: 2.15rem;
  margin-bottom: 0.75rem;
  font-size: 16px;
  line-height: 1.5;
}
.wpbm-checklist li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.05em;
  width: 1.45rem;
  height: 1.45rem;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2316C1A5' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='m8 12 3 3 5-6'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* ===== 10. ZOEKBALK ===== */
.wpbm-zoekbalk { max-width: 30rem; }
.wpbm-zoekbalk .wp-block-search__inside-wrapper {
  background: var(--base-3);
  border: 1px solid #e8ecf3;
  border-radius: var(--wpbm-radius-sm);
  box-shadow: var(--wpbm-shadow-sm);
  padding: 0.3rem;
}
.wpbm-zoekbalk input.wp-block-search__input {
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  padding: 0.7rem 0.75rem 0.7rem 2.6rem !important;
  font-size: 16px;
  color: var(--contrast);
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236C63FF' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E") no-repeat 0.8rem center / 1.15rem transparent !important;
}
.wpbm-zoekbalk input.wp-block-search__input:focus { outline: none; }
.wpbm-zoekbalk button.wp-block-search__button {
  background: var(--accent) !important;
  color: var(--base-3) !important;
  border: 0 !important;
  border-radius: var(--wpbm-radius-sm) !important;
  padding: 0.8rem 1.6rem !important;
  margin: 0 !important;
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
}
.wpbm-zoekbalk button.wp-block-search__button:hover { background: var(--contrast) !important; }

/* ===== 11. SECTIEKOP ===== */
.wpbm-sectiekop {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--wpbm-space-sm);
  margin-bottom: var(--wpbm-space-xl);
}
.wpbm-sectiekop h2 { margin-bottom: 0; }
.wpbm-sectiekop p { margin-bottom: 0; }

/* ===== 12. CATEGORIEKAARTEN ===== */
.wpbm-cat-grid { gap: var(--wpbm-space-md) !important; margin-bottom: 0; }
.wpbm-cat-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 100%;
  text-align: center;
  padding: var(--wpbm-space-lg) var(--wpbm-space-md);
}
.wpbm-cat-card figure { margin: 0 0 var(--wpbm-space-sm); }
.wpbm-cat-card img { width: 48px; height: 48px; }
.wpbm-cat-card h3 {
  margin: 0 0 var(--wpbm-space-xs);
  font-size: 18px;
  font-weight: 600;
}
.wpbm-cat-card p {
  font-size: 14px;
  line-height: 1.55;
  color: var(--wpbm-tekst-zacht);
  margin-bottom: var(--wpbm-space-md);
}
.wpbm-cat-card .wpbm-tekstlink { margin-top: auto; font-size: 15px; }

/* ===== 13. TRUST-BLOK ===== */
.wpbm-trust-grid { gap: var(--wpbm-space-lg) !important; margin-bottom: 0; }
.wpbm-trust-item figure { margin: 0 0 var(--wpbm-space-sm); }
.wpbm-trust-item img { width: 40px; height: 40px; }
.wpbm-trust-item h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 0.4rem;
}
.wpbm-trust-item p {
  font-size: 14px;
  line-height: 1.55;
  color: var(--wpbm-tekst-zacht);
  margin-bottom: 0;
}

/* ===== 14. RESPONSIVE ===== */
@media (min-width: 600px) and (max-width: 1024px) {
  .wpbm-cat-grid { flex-wrap: wrap !important; }
  .wpbm-cat-grid > .wp-block-column {
    flex-basis: calc(50% - var(--wpbm-space-md)) !important;
    flex-grow: 0;
  }
}

@media (max-width: 900px) {
  .wpbm-hero-badge {
    position: static;
    max-width: none;
    margin-top: var(--wpbm-space-sm);
  }
}

@media (max-width: 781px) {
  .wpbm-section { padding-block: var(--wpbm-space-2xl); }
  .wpbm-section > .wp-block-group__inner-container { padding-inline: var(--wpbm-space-sm); }
  .wpbm-hero { padding-block: 0; }
  .wpbm-hero-tekst { padding-block: var(--wpbm-space-2xl) 0; }
  .wpbm-hero h1, .wpbm-hero-intro { max-width: none; }
  .wpbm-hero-intro { font-size: 17px; }
  .wpbm-zoekbalk { max-width: none; }
  .wpbm-sectiekop { margin-bottom: var(--wpbm-space-lg); }
  .wpbm-footer-bar { flex-direction: column; gap: var(--wpbm-space-xs); text-align: center; }
}

/* ===== 15. CORRECTIES ===== */
.wpbm-hero-media .wp-block-image { width: 100%; }
.wpbm-hero-media .wp-block-image img { width: 100% !important; max-width: none; height: auto; }

.wpbm-hero-badge { width: 16.5rem; max-width: none; right: -2.5rem; bottom: 14%; }
.wpbm-hero-badge .wpbm-badge-titel { white-space: nowrap; }

@media (max-width: 1100px) {
  .wpbm-hero-badge { right: 0; width: 15rem; }
}
@media (max-width: 900px) {
  .wpbm-hero-badge { width: auto; }
}

/* ===== 16. LAYOUT-CORRECTIES ===== */
/* Core beperkt kinderen van een constrained groep tot de contentbreedte. */
/* Binnen onze secties bepalen wij de breedte zelf. */
.wpbm-section > .wp-block-group__inner-container > * { max-width: none; }

/* Groepsblokken plaatsen hun inhoud in een extra container. */
/* Layout-regels moeten daarom op die container staan. */
.wpbm-sectiekop > .wp-block-group__inner-container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--wpbm-space-sm);
}
.wpbm-sectiekop > .wp-block-group__inner-container > * { margin-block: 0; }

.wpbm-cat-card { padding: var(--wpbm-space-md) var(--wpbm-space-sm); }
.wpbm-cat-card > .wp-block-group__inner-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 100%;
}
.wpbm-cat-card > .wp-block-group__inner-container > * { margin-block: 0; }
.wpbm-cat-card h3 { font-size: 17px; margin: var(--wpbm-space-sm) 0 var(--wpbm-space-xs) !important; }
.wpbm-cat-card p { margin-bottom: var(--wpbm-space-md) !important; }
.wpbm-cat-card p:last-child { margin-top: auto; margin-bottom: 0 !important; }

.wpbm-trust-item > .wp-block-group__inner-container > * { margin-block: 0; }
.wpbm-trust-item h3 { margin: var(--wpbm-space-sm) 0 0.4rem !important; }

.wpbm-hero-badge > .wp-block-group__inner-container > * { margin-block: 0; }

/* ===== 17. FIJNAFSTELLING ===== */
/* De buitenste groep moet blok blijven; de flex zit op de binnencontainer. */
.wpbm-sectiekop { display: block; }
.wpbm-cat-card { display: block; }
.wpbm-trust-item { display: block; }

/* Kaarttekst past binnen 174px kolombreedte */
.wpbm-cat-card h3 { font-size: 15px; line-height: 1.35; }
.wpbm-cat-card p { font-size: 13px; line-height: 1.5; }
.wpbm-cat-card .wpbm-tekstlink { font-size: 14px; }
.wpbm-cat-card img { width: 44px; height: 44px; }
.wpbm-cat-grid { gap: var(--wpbm-space-sm) !important; }

/* Iets compactere secties */
.wpbm-section { padding-block: var(--wpbm-space-2xl); }
.wpbm-hero { padding-block: 0; }
.wpbm-hero-tekst { padding-block: var(--wpbm-space-2xl); }

/* ===== 18. FLEX-KINDEREN VOLLE BREEDTE ===== */
/* align-items:center laat kinderen krimpen; daardoor brak de titel af. */
.wpbm-cat-card > .wp-block-group__inner-container > * { width: 100%; }
.wpbm-cat-card > .wp-block-group__inner-container { align-items: stretch; }
.wpbm-cat-card figure { text-align: center; }
.wpbm-cat-card { padding: var(--wpbm-space-md) 0.75rem; }

.wpbm-trust-grid { gap: var(--wpbm-space-md) !important; }

