/* ==========================================================================
   PreventPartner – Professionals overzicht + profielpagina
   Loaded only by the overrides:
     html/com_content/category/professionals.php   (overview: see overview.css)
     html/com_content/article/profiel.php
   SUSE is already loaded by user.css.
   ========================================================================== */

:root {
  --pp-navy: #0C215B; --pp-navy-heading: #202E56; --pp-blue-deep: #143F6C;
  --pp-coral: #E06364; --pp-coral-text: #C24446; --pp-coral-text-on-grey: #B43C3E; /* 5.08:1 on #F1F1F1 (C24446 is only 4.42:1 there) */ --pp-mist: #C1CCD6; --pp-link: #224FAA;
  --pp-text: #22262A; --pp-text-muted: #333333;
  --pp-surface: #F1F1F1; --pp-footer: #D8D8D8; --pp-border: #CCCCCC; --pp-white: #FFFFFF;
  --pp-font: "SUSE", sans-serif; --pp-font-size: 1rem; --pp-line-height: 1.6;
  --pp-radius: 4px;
  --pp-space-1: 4px; --pp-space-2: 8px; --pp-space-3: 16px; --pp-space-4: 24px;
  --pp-space-5: 32px; --pp-space-6: 48px; --pp-space-7: 64px;
}

.pp-professionals,
.pp-profile {
  font-family: var(--pp-font);
  font-size: var(--pp-font-size);
  line-height: var(--pp-line-height);
  color: var(--pp-text);
}

/* Columns follow the width of the content column (works with or without sidebar).
   Note: a container also becomes the containing block for position:fixed children,
   so the sticky contact bar is rendered outside .pp-profile. */
.pp-professionals { container: pp-list / inline-size; }
.pp-profile       { container: pp-profile / inline-size; }

.pp-professionals :focus-visible,
.pp-profile :focus-visible,
.pp-mbar :focus-visible { outline: 3px solid var(--pp-link); outline-offset: 2px; }

/* Keep the focused element clear of the sticky contact bar (WCAG 2.4.11) */
html:has(.pp-mbar.is-visible) { scroll-padding-bottom: 104px; }

.pp-professionals p,
.pp-profile p,
.pp-mbar p { margin: 0; }
.pp-profile address { margin: 0; font-style: normal; }

/* ---------- Shared bits ---------- */

.pp-professionals .pp-eyebrow,
.pp-profile .pp-eyebrow {
  margin: 0;
  font-size: .8125rem;
  line-height: 18px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--pp-coral-text-on-grey);
}

.pp-professionals .pp-arrow,
.pp-profile .pp-arrow { font-weight: 600; color: var(--pp-navy); }
.pp-professionals .pp-arrow::after,
.pp-profile .pp-arrow::after { content: " >"; }

.pp-icon { width: 16px; height: 16px; flex: none; fill: currentColor; color: var(--pp-navy); }

.pp-initials {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  font-size: 2.5rem;
  font-weight: 600;
  letter-spacing: .04em;
  color: var(--pp-navy);
  background: var(--pp-surface);
}

/* Buttons (style guide: primary navy, secondary white with #CCC border, no coral buttons) */
.pp-profile .pp-btn,
.pp-profile .pp-btn--mail a,
.pp-mbar .pp-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--pp-space-2);
  padding: 10px 16px;
  font: inherit;
  font-size: 1rem;
  line-height: 1.4;
  color: var(--pp-white);
  text-decoration: none;
  background: var(--pp-navy);
  border: 1px solid var(--pp-navy);
  border-radius: var(--pp-radius);
}
.pp-profile .pp-btn:hover,
.pp-profile .pp-btn--mail a:hover,
.pp-mbar .pp-btn:hover { background: var(--pp-navy-heading); color: var(--pp-white); }

/* Mail button: the wrapper is a span, the cloaked <a> inside gets the button look */
.pp-profile .pp-btn.pp-btn--mail { padding: 0; background: none; border: 0; }

.pp-profile .pp-btn--sec {
  color: var(--pp-text-muted);
  background: var(--pp-white);
  border-color: var(--pp-border);
}
.pp-profile .pp-btn--sec:hover { color: var(--pp-navy); background: var(--pp-white); border-color: var(--pp-navy); }

/* ==========================================================================
   Overzicht: the cards, grid, head band and filter row are in overview.css
   (shared with the news overview and mod_prevent_professionals).
   ========================================================================== */

/* Profile photos in greyscale (profile page; the overview cards: overview.css) */
.pp-profile__portrait img,
.pp-profile__img {
  filter: grayscale(100%);
}

/* ==========================================================================
   Profielpagina
   ========================================================================== */

.pp-profile .pp-profile__hero {
  display: grid;
  gap: var(--pp-space-4);
  padding: var(--pp-space-4) var(--pp-space-3);
  background: var(--pp-surface);
  border-radius: var(--pp-radius);
}
@container pp-profile (min-width: 640px) {
  .pp-profile .pp-profile__hero {
    grid-template-columns: minmax(200px, 320px) minmax(0, 1fr);
    align-items: start;
    gap: var(--pp-space-5);
    padding: var(--pp-space-5);
  }
}
@supports not (container-type: inline-size) {
  @media (min-width: 768px) {
    .pp-profile .pp-profile__hero { grid-template-columns: minmax(200px, 320px) minmax(0, 1fr); align-items: start; gap: var(--pp-space-5); padding: var(--pp-space-5); }
  }
}

.pp-profile__portrait {
  order: -1; /* after the h1 in the DOM, left/top visually */
  width: 100%;
  max-width: 320px; /* square portrait, max 320px */
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--pp-white);
  border: 1px solid var(--pp-border);
  border-radius: var(--pp-radius);
}
.pp-profile__portrait img,
.pp-profile__img {
  display: block;
  width: 100%;
  height: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  object-position: 50% 20%;
}

.pp-profile__intro { display: flex; flex-direction: column; gap: var(--pp-space-4); min-width: 0; }
.pp-profile .pp-profile__name { display: flex; flex-direction: column; gap: var(--pp-space-2); margin: 0; }
.pp-profile .pp-profile__name .pp-eyebrow { order: -1; color: var(--pp-coral-text-on-grey); }
.pp-profile .pp-profile__section-title { margin: 0; }

/* Free-format expertises, right below the name (no label) */
.pp-profile .pp-profile__specialties {
  margin: 0;
  font-size: 1.0625rem;
  line-height: 1.5;
  color: var(--pp-text-muted);
}

/* Publications (editor field): last block of the profile intro, below the LinkedIn link */
.pp-profile .pp-profile__publications {
  display: flex;
  flex-direction: column;
  gap: var(--pp-space-2);
  padding-top: var(--pp-space-3);
  border-top: 1px solid var(--pp-border);
}
.pp-profile .pp-profile__publications .pp-eyebrow { color: var(--pp-coral-text-on-grey); } /* hero is grey */
.pp-profile .pp-profile__publications-body { max-width: 65ch; font-size: .9375rem; }
.pp-profile .pp-profile__publications-body p,
.pp-profile .pp-profile__publications-body ul,
.pp-profile .pp-profile__publications-body ol { margin: 0 0 .75rem; }
.pp-profile .pp-profile__publications-body ul,
.pp-profile .pp-profile__publications-body ol { padding-left: 1.25rem; }
.pp-profile .pp-profile__publications-body li + li { margin-top: var(--pp-space-1); }
.pp-profile .pp-profile__publications-body > :last-child { margin-bottom: 0; }
.pp-profile .pp-profile__publications-body a { color: var(--pp-link); overflow-wrap: anywhere; }
.pp-profile .pp-profile__publications-body img { max-width: 100%; height: auto; }

.pp-profile .pp-profile__title {
  margin: 0;
  font-size: clamp(1.625rem, 5cqi, 2rem);
  line-height: 1.3;
  font-weight: 600;
  color: var(--pp-navy-heading);
  text-wrap: balance;
}

.pp-profile .pp-contact-row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--pp-space-3); }
.pp-profile .pp-phone { display: inline-flex; flex-wrap: wrap; align-items: center; gap: var(--pp-space-2); font-size: .9375rem; }
.pp-profile .pp-contact-row .pp-phone { flex-basis: 100%; } /* "Bel direct" always on its own line */
/* "Ervaring bij" in the contact row: no extra padding, and "Bel direct" close below it */
.pp-profile .pp-contact-row .pp-facts { margin: 0; }
.pp-profile .pp-contact-row .pp-facts__row { display: block; padding: 0; } /* inline: "Ervaring bij: content" */
.pp-profile .pp-contact-row .pp-facts dt,
.pp-profile .pp-contact-row .pp-facts dd { display: inline; }
.pp-profile .pp-contact-row .pp-facts dt { margin-right: .25em; font-weight: 400; color: var(--pp-text); }
.pp-profile .pp-contact-row .pp-facts dd { font-weight: 600; color: var(--pp-navy-heading); }
.pp-profile .pp-contact-row .pp-facts + .pp-phone { margin-top: calc(-1 * var(--pp-space-2)); }
.pp-profile .pp-phone a { color: var(--pp-navy-heading); text-underline-offset: 3px; }
.pp-profile .pp-phone a:hover { text-decoration-thickness: 2px; }
.pp-profile .pp-phone strong { font-weight: 600; font-variant-numeric: tabular-nums; }
.pp-profile .pp-online { display: flex; flex-direction: column; gap: var(--pp-space-2); }
.pp-profile .pp-meta { font-size: .8125rem; line-height: 18px; color: var(--pp-text-muted); }
.pp-profile .pp-socials { display: flex; flex-wrap: wrap; gap: var(--pp-space-2); margin: 0; padding: 0; list-style: none; }
.pp-profile .pp-socials a {
  display: inline-flex;
  align-items: center;
  gap: var(--pp-space-2);
  padding: 6px 10px;
  font-size: .875rem;
  color: var(--pp-navy);
  text-decoration: none;
  background: var(--pp-white);
  border: 1px solid var(--pp-border);
  border-radius: var(--pp-radius);
}
.pp-profile .pp-socials a:hover { border-color: var(--pp-navy); }
.pp-profile .pp-socials .pp-icon { width: 18px; height: 18px; }

/* Expertises on the profile: link tiles, 3 / 2 / 1 columns */
.pp-profile .pp-profile__expertises { margin-top: var(--pp-space-6); }
.pp-profile .pp-section-head { display: flex; flex-direction: column; gap: var(--pp-space-2); margin: 0 0 var(--pp-space-4); }
.pp-profile .pp-section-head .pp-eyebrow { order: -1; }
.pp-profile .pp-section-head__title { margin: 0; font-size: 1.5rem; line-height: 2.25rem; font-weight: 600; color: var(--pp-navy-heading); }

.pp-profile .pp-exp-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--pp-space-3);
  margin: 0;
  padding: 0;
  list-style: none;
}
@container pp-profile (min-width: 540px) {
  .pp-profile .pp-exp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@container pp-profile (min-width: 820px) {
  .pp-profile .pp-exp-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@supports not (container-type: inline-size) {
  @media (min-width: 576px) { .pp-profile .pp-exp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
  @media (min-width: 992px) { .pp-profile .pp-exp-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
}
.pp-profile .pp-exp-grid li { display: flex; }

.pp-profile .pp-exp {
  display: flex;
  flex-direction: column;
  gap: var(--pp-space-3);
  width: 100%;
  padding: var(--pp-space-3) var(--pp-space-4) var(--pp-space-4);
  color: inherit;
  text-decoration: none;
  background: var(--pp-white);
  border: 1px solid var(--pp-border);
  border-top: 3px solid var(--pp-navy);
  border-radius: var(--pp-radius);
}
.pp-profile .pp-exp__title { font-size: 1.125rem; line-height: 25px; font-weight: 600; color: var(--pp-navy-heading); }
.pp-profile .pp-exp .pp-arrow { margin-top: auto; font-size: .9375rem; }
.pp-profile .pp-exp:hover { border-color: var(--pp-navy); }
.pp-profile .pp-exp:hover .pp-exp__title { text-decoration: underline; }

/* Biography + contact tile */
.pp-profile .pp-profile__main {
  display: grid;
  gap: var(--pp-space-5);
  margin-top: var(--pp-space-6);
}
@container pp-profile (min-width: 820px) {
  .pp-profile .pp-profile__main { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: start; }
}
@supports not (container-type: inline-size) {
  @media (min-width: 992px) { .pp-profile .pp-profile__main { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: start; } }
}

.pp-profile .pp-profile__bio { display: flex; flex-direction: column; gap: var(--pp-space-3); min-width: 0; }
.pp-profile .pp-profile__body { max-width: 65ch; }
.pp-profile .pp-profile__body p,
.pp-profile .pp-profile__body ul,
.pp-profile .pp-profile__body ol { margin: 0 0 1rem; }
.pp-profile .pp-profile__body > :first-child { margin-top: 0; }
.pp-profile .pp-profile__body > :last-child { margin-bottom: 0; }
.pp-profile .pp-profile__body h2 { font-size: 1.5rem; line-height: 36px; margin: var(--pp-space-5) 0 var(--pp-space-2); }
.pp-profile .pp-profile__body h3 { font-size: 1.125rem; line-height: 25px; margin: var(--pp-space-4) 0 var(--pp-space-2); }
.pp-profile .pp-profile__body p:first-child { font-weight: 600; } /* lead line, as in the wireframe */
.pp-profile .pp-profile__body a { color: var(--pp-link); }
.pp-profile .pp-profile__body img { max-width: 100%; height: auto; }

/* Key facts under the biography ("Ervaring bij"): label left, values right; stacked on narrow screens */
.pp-profile .pp-facts { max-width: 65ch; margin: var(--pp-space-2) 0 0; }
.pp-profile .pp-facts__row {
  display: grid;
  gap: var(--pp-space-1) var(--pp-space-4);
  padding: var(--pp-space-3) 0;
}
@container pp-profile (min-width: 540px) {
  .pp-profile .pp-facts__row { grid-template-columns: minmax(8rem, 1fr) 3fr; }
}
.pp-profile .pp-facts dt { font-weight: 600; color: var(--pp-navy-heading); }
.pp-profile .pp-facts dd { margin: 0; }
.pp-profile .pp-facts__list { display: grid; gap: var(--pp-space-1); margin: 0; padding: 0; list-style: none; }
.pp-profile .pp-facts__list li { position: relative; padding-left: var(--pp-space-3); }
.pp-profile .pp-facts__list li::before {
  content: "";
  position: absolute;
  top: .7em;
  left: 0;
  width: 6px;
  height: 6px;
  background: var(--pp-coral); /* decorative marker; coral only for shapes, not text */
  border-radius: 1px;
}

.pp-profile .pp-profile__side { display: flex; flex-direction: column; align-items: flex-start; gap: var(--pp-space-3); }
@container pp-profile (min-width: 820px) {
  .pp-profile .pp-profile__side { position: sticky; top: var(--pp-space-4); }
}

.pp-profile .pp-tile {
  align-self: stretch;
  display: flex;
  flex-direction: column;
  gap: var(--pp-space-3);
  padding: var(--pp-space-4);
  border-radius: var(--pp-radius);
  scroll-margin-top: var(--pp-space-6);
}
.pp-profile .pp-tile--blue { background: var(--pp-blue-deep); color: var(--pp-white); }
.pp-profile .pp-tile__title { margin: 0; font-size: 1.125rem; line-height: 25px; font-weight: 600; color: var(--pp-white); }

.pp-profile .pp-links { display: grid; gap: var(--pp-space-3); margin: 0; padding: 0; list-style: none; }
.pp-profile .pp-links li { display: flex; flex-direction: column; min-width: 0; }
.pp-profile .pp-links .pp-links__label { font-size: .8125rem; line-height: 18px; color: var(--pp-mist); }
.pp-profile .pp-links a {
  display: flex;
  justify-content: space-between;
  gap: var(--pp-space-3);
  color: var(--pp-white);
  text-decoration: none;
  overflow-wrap: anywhere;
}
.pp-profile .pp-links a::after { content: ">"; flex: none; }
.pp-profile .pp-links a:hover { text-decoration: underline; }
.pp-profile .pp-tile--blue :focus-visible { outline-color: var(--pp-white); } /* 10.7:1 on deep blue */
.pp-profile .pp-tile:focus { outline: 3px solid var(--pp-navy); outline-offset: 2px; }
.pp-profile .pp-links joomla-hidden-mail { display: block; }

/* Sticky contact bar (mobile: full width bottom bar, desktop: small floating card) */
.pp-mbar {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 1020;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--pp-space-2);
  padding: var(--pp-space-2) var(--pp-space-3) calc(var(--pp-space-2) + env(safe-area-inset-bottom, 0px));
  font-family: var(--pp-font);
  background: var(--pp-white);
  border-top: 1px solid var(--pp-border);
  visibility: hidden;
  transform: translateY(calc(100% + 48px));
  transition: transform .2s, visibility .2s;
}
.pp-mbar.is-visible { visibility: visible; transform: none; }
.pp-mbar .pp-btn { flex: none; }
.pp-mbar__who { font-size: .875rem; line-height: 1.3; color: var(--pp-text-muted); }
.pp-mbar__who b { display: block; font-weight: 600; color: var(--pp-navy-heading); }
@media (min-width: 860px) {
  .pp-mbar {
    right: var(--pp-space-4);
    bottom: var(--pp-space-4);
    left: auto;
    gap: var(--pp-space-3);
    padding: var(--pp-space-2) var(--pp-space-3);
    border: 1px solid var(--pp-border);
    border-radius: var(--pp-radius);
    box-shadow: 0 2px 8px rgba(12, 33, 91, .12);
  }
}
@media (prefers-reduced-motion: reduce) { .pp-mbar { transition: none; } }
@media print { .pp-mbar { display: none !important; } }

/* Windows high contrast / forced colors */
@media (forced-colors: active) {
  .pp-profile .pp-tile, .pp-profile .pp-profile__hero, .pp-mbar { border: 1px solid CanvasText; }
  .pp-initials { forced-color-adjust: none; }
}
