/* ================================================================
   Expert Profile — Full View CSS
   File: themes/theme_acbf/css/expert-profile.css

   Add to theme_acbf.libraries.yml:

   global-styling-and-scripts:
     css:
       theme:
         css/expert-profile.css: {}
   ================================================================ */

/* ── Variables ─────────────────────────────────────────────── */
:root {
  --ep-green:   #96c882;
  --ep-green2:  #2f6320;
  --ep-green-text: #3f7a2c;
  --ep-gold:    #e8c16a;
  --ep-gold2:   #f0d080;
  --ep-ink:     #1C1C2E;
  --ep-ink2:    #2d2d4a;
  --ep-cream:   #F7F5F0;
  --ep-muted:   #6B6B7A;
  --ep-border:  #E8E4DC;
  --ep-white:   #ffffff;
  --ep-shadow:  0 4px 24px rgba(28,28,46,.08);
  --ep-radius:  14px;
}

/* ── PAGE BACKGROUND ───────────────────────────────────────── */
.ep-body {
  padding: 40px 0 64px;
}

/* ================================================================
   HERO
   ================================================================ */
.ep-hero {
  background: linear-gradient(135deg, #ffffff 0%, #e1e1e1 55%, #effff4 100% 100%) !important;
  position: relative;
  overflow: hidden;
  padding: 40px 40px 0;
  margin-bottom: 0;
  margin-top: 30px;
  border-radius: 10px;
      border: 1px solid #dfdfdf;
    box-shadow: var(--box-shadow-md);
        position: sticky;
    z-index: 1;
    top: 100px;
}
.sub-title-option{
  /* display: flex; */
    align-items: center;
    justify-content: start;
    gap: 10px;
}
.ep-hero-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(232,193,106,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(232,193,106,.05) 1px, transparent 1px);
  background-size: 52px 52px;
  pointer-events: none;
}
.ep-hero-orb-1 {
  position: absolute; top: -100px; right: -80px;
  width: 480px; height: 480px;
  background: radial-gradient(circle, rgba(232,193,106,.14) 0%, transparent 65%);
  border-radius: 50%; pointer-events: none;
}
.ep-hero-orb-2 {
  position: absolute; bottom: -60px; left: 5%;
  width: 280px; height: 280px;
  background: radial-gradient(circle, rgba(150,200,130,.16) 0%, transparent 65%);
  border-radius: 50%; pointer-events: none;
}

/* ── Hero top row ──────────────────────────────────────────── */
.ep-hero-top {
  display: flex;
  align-items: self-start;
  gap: 28px;
  padding-bottom: 32px;
  position: relative;
  z-index: 2;
}

/* ── Avatar ────────────────────────────────────────────────── */
.ep-avatar-wrap {
  position: relative;
  width: 120px; height: 120px;
  flex-shrink: 0;
}
.ep-avatar-wrap img,
.ep-avatar-wrap .field--name-field-profile-photo img {
  width: 120px !important;
  height: 120px !important;
  border-radius: 50% !important;
  object-fit: contain !important;
  border: 1px solid var(--primary);
  box-shadow: 0 8px 32px rgba(0,0,0,.35) !important;
  display: block;
}
.ep-initials {
  width: 120px; height: 120px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--ep-gold), var(--ep-green));
  display: flex; align-items: center; justify-content: center;
  font-size: 38px; font-weight: 700; color: #fff;
  border: 4px solid rgba(232,193,106,.5);
  box-shadow: 0 8px 32px rgba(0,0,0,.35);
  letter-spacing: -1px;
}
.ep-verified {
  position: absolute; bottom: 2px; right: 2px;
  width: 26px; height: 26px;
  background: var(--ep-green, #96c882);
  border: 2px solid #fff;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 11px; font-weight: 700;
  box-shadow: 0 2px 8px rgba(0,0,0,.2);
}

/* ── Hero info ─────────────────────────────────────────────── */
.ep-hero-info { flex: 1; min-width: 0; display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 24px;}

.ep-name {
  font-size: 28px;
  font-weight: 700; color: var(--text-primary);
  margin: 0 0 6px; line-height: 1.15;
  letter-spacing: -.3px;
}
/* Title + verified badge on one baseline. Works whether the badge is a
   child of .ep-name or a sibling inside .ep-name-row. */
.ep-name-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 10px;
}
.ep-name-row .ep-name { margin-bottom: 0; }

/* Small edit-profile icon button (admin only) */
.ep-edit-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px;
  border-radius: 8px;
  background: rgba(0,0,0,.05);
  border: 1px solid rgba(0,0,0,.12);
  color: #4a5a68;
  font-size: 13px;
  text-decoration: none;
  transition: background .15s, color .15s, border-color .15s;
}
.ep-edit-btn:hover {
  background: var(--btn-primary, #96c882);
  border-color: var(--btn-primary, #96c882);
  color: var(--on-primary, #102828);
}

/* Hero sub-title: org / designation / expertise as a tidy vertical list */
.sub-title-option {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 5px;
  margin-bottom: 14px;
}
.sub-title-option .ep-org {
  margin: 0;
  font-size: 14px;
  font-weight: 500;
  color: #4a5a68;
}
.sub-title-option .ep-org a { color: var(--ep-green-text); }
.sub-title-option .ep-org i { color: #8a97a3; width: 16px; text-align: center; }

/* Views + moderation status row */
.ep-meta-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
.ep-view-count {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; font-weight: 600;
  color: #4a5a68;
  background: rgba(0,0,0,.04);
  border: 1px solid rgba(0,0,0,.12);
  border-radius: 20px;
  padding: 5px 14px;
  cursor: default;
}
.ep-verified-badge {
  display: inline-flex;
  align-items: center;
  vertical-align: middle;
  font-size: 20px;
  line-height: 1;
  color: #1d9bf0;
}
.ep-name .ep-verified-badge { margin-left: 8px; font-size: .68em; }
.ep-verified-badge i { display: block; }
.ep-designation {
  font-size: 15px; color: #4a5a68;
  margin-bottom: 4px; font-weight: 400;
}
.ep-title-meta {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  margin: 8px 0 0;
  padding: 0;
}
.ep-title-meta li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: #3a4a58;
}
.ep-title-meta li i {
  color: #3f7a2c;
  font-size: 12px;
}
.ep-org {
  font-size: 14px; color: var(--ep-muted);
  font-weight: 600; margin-bottom: 16px;
}
.ep-org i { margin-right: 5px; }

/* Expertise badges in hero */
.ep-hero-badges { margin-bottom: 18px; }
.ep-hero-badge {
  display: inline-flex; align-items: center;
  background: rgba(232,193,106,.12);
  border: 1px solid rgba(232,193,106,.28);
  color: var(--ep-gold);
  font-size: 12px; font-weight: 600;
  padding: 4px 12px; border-radius: 99px;
  margin: 0 6px 6px 0;
}

/* Action buttons */
.ep-hero-actions {
  display: flex; align-items: center;
  flex-wrap: wrap; gap: 8px;
}
.ep-btn {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 16px; font-weight: 600;
  padding: 8px 18px; border-radius: 8px;
  text-decoration: none; transition: all .2s;
  border: none; cursor: pointer;
  font-family: inherit;
  min-height: 42px;
  justify-content: center;
}
.ep-btn:hover{
  background-color: #525252 !important;
  color: #ffffff !important;
}
.ep-btn-outline {
    background: rgb(150 150 150 / 63%);
    border: 1px solid var(--gray-border);
    color: #ffffff;
    border-radius: 50px;
    min-width: 55px;
}
.ep-btn-outline:hover {
  background: rgb(181, 255, 220);
  color: #fff; text-decoration: none;
}
.ep-btn-icon {
  width: 36px; height: 36px; padding: 0;
  justify-content: center;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.15);
  color: rgba(255,255,255,.7);
  border-radius: 8px;
}
.ep-btn-icon:hover {
  background: rgba(232,193,106,.15);
  border-color: rgba(232,193,106,.35);
  color: var(--ep-gold);
  text-decoration: none;
}

/* ── Stats strip ───────────────────────────────────────────── */
.ep-stats-strip {
  display: flex;
  border-top: 1px solid rgba(255,255,255,.08);
  position: relative; z-index: 2;
}
.ep-stat {
  flex: 1;
  padding: 16px 20px;
  text-align: center;
  border-right: 1px solid rgba(255,255,255,.07);
}
.ep-stat:last-child { border-right: none; }
.ep-stat-num {
  display: block;
  font-size: 20px; font-weight: 700;
  color: var(--ep-gold); line-height: 1;
  margin-bottom: 4px;
}
.ep-stat-label {
  display: block;
  font-size: 10px; font-weight: 600;
  letter-spacing: .09em; text-transform: uppercase;
  color: rgba(255,255,255,.38);
}

/* ================================================================
   SIDEBAR CARDS
   ================================================================ */
.ep-card {
  background: var(--ep-white);
  border-radius: var(--ep-radius);
  box-shadow: var(--ep-shadow);
  margin-bottom: 20px;
  overflow: hidden;
  border: 1px solid var(--ep-border);
}
.ep-card-head {
  padding: 16px 24px;
  font-size: 18px; font-weight: 700;
  color: #000;
  display: flex; align-items: center; gap: 8px;
  position: relative;
  border-bottom: 1px solid var(--ep-border);
}

.ep-card-head::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, var(--ep-gold), var(--ep-green));
    border-radius: 0 2px 2px 0;
}

.ep-card-body { padding: 18px; }

/* Contact rows */
.ep-contact-row {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--ep-border);
  justify-content: stretch;
}
.ep-contact-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}
.ep-contact-icon {
  width: 32px; height: 32px;
  background: #dffde8;
  border-radius: 18px;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; flex-shrink: 0;
}

.ep-contact-icon i { color: #3f7a2c; }
.ep-contact-label {
  font-size: 10px; font-weight: 600;
  color: var(--ep-muted); line-height: 1; margin-bottom: 3px;
  text-wrap: nowrap;
}
.ep-contact-value {
  font-size: 14px; color: var(--ep-ink); font-weight: 500;
  word-break: break-all; line-height: 1.4;
}
.ep-contact-value a {
  color: var(--ep-green-text); text-decoration: none;
}
.ep-contact-value a:hover { text-decoration: underline; }

/* Expertise tags in sidebar */
.ep-tag {
  display: inline-flex; align-items: center;
  background: rgba(150,200,130,.08);
  border: 1px solid rgba(150,200,130,.2);
  color: var(--ep-green-text);
  font-size: 12px; font-weight: 600;
  padding: 5px 12px; border-radius: 50px;
  margin: 0 6px 6px 0;
}

/* Address body */
.ep-address-body {
  font-size: 14px; color: var(--ep-muted);
  line-height: 1.7;
}
.ep-address-body .field--name-field-address { font-size: 14px; }

/* Documents */
.ep-card-body .file a,
.ep-card-body .file--mime-text-plain a {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--ep-green-text); font-weight: 600; font-size: 14px;
  text-decoration: none;
}
.ep-card-body .file a:hover { color: var(--ep-green2); }

/* ================================================================
   MAIN CONTENT SECTIONS
   ================================================================ */
.ep-section {
  background: var(--ep-white);
  border-radius: var(--ep-radius);
  box-shadow: var(--ep-shadow);
  margin-bottom: 20px;
  overflow: hidden;
  border: 1px solid var(--ep-border);
}

.ep-section-head {
  display: flex; align-items: center; gap: 12px;
  padding: 16px 24px;
  border-bottom: 1px solid var(--ep-border);
  position: relative;
}
.ep-section-head::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, var(--ep-gold), var(--ep-green));
  border-radius: 0 2px 2px 0;
}
.ep-section-icon {
  width: 38px; height: 38px;
  background: linear-gradient(135deg, rgba(232,193,106,.12), rgba(150,200,130,.08));
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; flex-shrink: 0;
}
.ep-section-title {
  font-size: 18px; font-weight: 700;
  color: var(--ep-ink); margin: 0; line-height: 1.2;
  letter-spacing: -.2px;
}

.ep-section-body {
  padding: 24px;
  font-size: 15px; line-height: 1.8;
  color: #4A4A5A;
}
.ep-section-body p { margin-bottom: 12px; }
.ep-section-body p:last-child { margin-bottom: 0; }
.ep-section-body ul { padding-left: 18px; }
.ep-section-body li { margin-bottom: 6px; }
.ep-section-body strong { color: var(--ep-ink); }
.ep-section-body em { color: var(--ep-green-text); }

/* ── Download file link inside section body ────────────────── */
.ep-section-body .file a {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--ep-green-text); font-weight: 600; font-size: 14px;
  text-decoration: none;
}
.ep-section-body .file a:hover { color: var(--ep-green2); }

/* ================================================================
   RESPONSIVE
   ================================================================ */
@media (max-width: 991px) {
  .ep-hero { padding: 40px 0 0; }
  .ep-hero-top { flex-direction: column; align-items: center; text-align: center; gap: 20px; padding-bottom: 28px; }
  .ep-hero-badges { justify-content: center; display: flex; flex-wrap: wrap; }
  .ep-hero-actions { justify-content: center; }
  .ep-name { font-size: 26px; }
}

@media (max-width: 576px) {
  .ep-stats-strip { flex-wrap: wrap; }
  .ep-stat { flex: 0 0 50%; }
  .ep-stat:nth-child(2) { border-right: none; }
  .ep-section-body { padding: 18px; }
  .ep-card-body { padding: 14px; }
}

/* ── Admin status badge ──────────────────────────────── */
.ep-status-badge {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 12px; font-weight: 700; letter-spacing: .4px;
  padding: 5px 12px; border-radius: 20px;
  text-transform: uppercase;
}
.ep-status--published  { background: rgba(150,200,130,.25);  color: #3f7a2c; border: 1px solid rgba(150,200,130,.6); }
.ep-status--draft      { background: rgba(234,179,8,.15);  color: #a16207; border: 1px solid rgba(234,179,8,.4); }
.ep-status--archived   { background: rgba(100,116,139,.14); color: #475569; border: 1px solid rgba(100,116,139,.35); }
.ep-status--blocked    { background: rgba(239,68,68,.14);  color: #b91c1c; border: 1px solid rgba(239,68,68,.4); }
.ep-status--review     { background: rgba(99,102,241,.14); color: #4338ca; border: 1px solid rgba(99,102,241,.4); }
.ep-status--default    { background: rgba(0,0,0,.05); color: #4a5a68; border: 1px solid rgba(0,0,0,.15); }




/* ================================================================
   NEW DESIGN (Knowledge Hub redesign) — dark hero, flat sections,
   "Profile details" aside. Overrides the rules above.
   ================================================================ */
:root {
  --ep-d-ink:        #163a40;
  --ep-d-ink-soft:   #24505a;
  --ep-d-ink-fg:     #f5faf2;
  --ep-d-leaf:       #94d27c;
  --ep-d-leaf-soft:  #eaf6e4;
  --ep-d-signal:     #e8552b;
  --ep-d-muted:      #f2f5ef;
  --ep-d-muted-fg:   #5a6b70;
  --ep-d-border:     #dbe6d6;
}
@supports (color: oklch(0% 0 0)) {
  :root {
    --ep-d-ink:       oklch(27% .035 205);
    --ep-d-ink-soft:  oklch(34% .04 205);
    --ep-d-ink-fg:    oklch(98% .008 130);
    --ep-d-leaf:      oklch(79% .11 138);
    --ep-d-leaf-soft: oklch(95% .035 138);
    --ep-d-signal:    oklch(62% .2 37);
    --ep-d-muted:     oklch(96.5% .01 130);
    --ep-d-muted-fg:  oklch(50% .025 205);
    --ep-d-border:    oklch(91% .015 140);
  }
}

/* Hero */
.ep-expert .ep-hero {
  background: var(--ep-d-ink) !important;
  color: var(--ep-d-ink-fg);
  border: 0;
  border-radius: 0;
  box-shadow: none;
  position: relative;
  top: auto;
  margin: 0;
  padding: 32px 0 48px;
}
.ep-expert .ep-breadcrumb {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  font-size: 14px; color: rgba(245,250,242,.7);
}
.ep-expert .ep-breadcrumb a { color: inherit; text-decoration: none; }
.ep-expert .ep-breadcrumb a:hover { color: var(--ep-d-leaf); }
.ep-expert .ep-breadcrumb-current { color: var(--ep-d-ink-fg); }

.ep-expert .ep-hero-top { align-items: center; gap: 48px; padding: 40px 0 0; }
.ep-expert .ep-avatar-wrap { width: 240px; height: 240px; }
.ep-expert .ep-avatar-wrap img, .ep-expert .ep-avatar-wrap .field--name-field-profile-photo img {
  width: 240px !important; height: 240px !important;
  max-width: 100%;
  border-radius: 8px !important;
  object-fit: cover !important;
  border: 4px solid var(--ep-d-ink-soft) !important;
  box-shadow: 0 2px 4px rgba(0,0,0,.12), 0 22px 40px -18px rgba(0,0,0,.5) !important;
}
.ep-expert .ep-initials {
  width: 240px; height: 240px; border-radius: 8px; font-size: 72px;
  background: var(--ep-d-ink-soft); border: 4px solid var(--ep-d-ink-soft);
}
.ep-expert .ep-hero-info { display: block; }
.ep-expert .ep-eyebrow {
  margin: 0 0 12px; font-size: 12px; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase; color: var(--ep-d-leaf);
}
.ep-expert .ep-name { font-size: 40px; font-weight: 700; line-height: 1.15; color: var(--ep-d-ink-fg); overflow-wrap: anywhere; }
.ep-expert .ep-name-row { margin-bottom: 0; }
.ep-expert .ep-role { margin: 16px 0 0; font-size: 18px; color: var(--ep-d-leaf); }
.ep-expert .sub-title-option { margin: 12px 0 0; gap: 10px; }
.ep-expert .sub-title-option .ep-org { font-size: 14px; font-weight: 400; color: rgba(245,250,242,.8); display: flex; align-items: flex-start; gap: 8px; }
.ep-expert .sub-title-option .ep-org i { color: inherit; width: 16px; margin-top: 3px; }
.ep-expert .sub-title-option .ep-org a { color: inherit; text-decoration: none; }
.ep-expert .sub-title-option .ep-org a:hover { color: var(--ep-d-leaf); }
.ep-expert .ep-hero .ep-edit-btn { background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.25); color: var(--ep-d-ink-fg); }
.ep-expert .ep-hero .verified-icon { color: var(--ep-d-leaf); }

.ep-expert .ep-hero-cta { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-top: 24px; }
.ep-expert .ep-contact-btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--ep-d-signal); color: #fff; font-size: 14px; font-weight: 500;
  padding: 10px 20px; border-radius: 999px; text-decoration: none;
  transition: filter .2s;
}
.ep-expert .ep-contact-btn:hover { filter: brightness(.92); color: #fff; }
.ep-expert .ep-hero .ep-btn-outline { background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.25); color: var(--ep-d-ink-fg); min-width: 44px; min-height: 40px; padding: 6px 12px; }
.ep-expert .ep-hero .ep-btn-outline:hover { background: var(--ep-d-leaf) !important; color: var(--ep-d-ink) !important; }
.ep-expert .ep-hero .ep-meta-actions { margin-top: 20px; }
.ep-expert .ep-hero .ep-view-count { color: rgba(245,250,242,.8); background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.2); }

/* Body */
.ep-expert .ep-body { padding: 48px 0 64px; }
.ep-expert .ep-section, .ep-expert .ep-card {
  border-radius: 0; box-shadow: none; border: 0;
  border-bottom: 1px solid var(--ep-d-border);
  background: transparent;
}
.ep-expert .ep-section { padding-bottom: 28px; margin-bottom: 28px; }
.ep-expert .ep-section-head, .ep-expert .ep-card-head { padding: 0 0 12px; border-bottom: 0; }
.ep-expert .ep-section-head::before, .ep-expert .ep-card-head::before { display: none; }
.ep-expert .ep-section-title { font-size: 24px; font-weight: 600; color: var(--ep-d-ink); letter-spacing: 0; }
.ep-expert .ep-section-icon { background: var(--ep-d-leaf-soft); color: var(--ep-d-signal); border-radius: 50%; }
.ep-expert .ep-section-body { padding: 8px 0 0; font-size: 16px; line-height: 2; color: var(--ep-d-muted-fg); }
.ep-expert .ep-section-body strong { color: var(--ep-d-ink); }

/* Aside → "Profile details" panel */
.ep-expert .ep-aside > .ep-card {
  background: var(--ep-d-muted);
  border-left: 4px solid var(--ep-d-leaf);
  border-bottom: 0;
  padding: 24px;
  margin-bottom: 20px;
}
.ep-expert .ep-aside .ep-card-head { font-size: 18px; font-weight: 600; color: var(--ep-d-ink); }
.ep-expert .ep-aside .ep-card-body { padding: 8px 0 0; }
.ep-expert .ep-aside .ep-card-head .ep-section-icon { background: transparent; color: var(--ep-d-signal); width: auto; height: auto; font-size: 18px; }
.ep-expert .ep-aside .ep-contact-row { border-bottom: 0; padding: 8px 0; align-items: flex-start; }
.ep-expert .ep-aside .ep-contact-icon { background: transparent; width: 20px; height: 20px; border-radius: 0; }
.ep-expert .ep-aside .ep-contact-icon i { color: var(--ep-d-signal); }
.ep-expert .ep-aside .ep-contact-label { font-size: 13px; font-weight: 400; color: var(--ep-d-muted-fg); margin-bottom: 4px; line-height: 1.3; }
.ep-expert .ep-aside .ep-contact-value { font-size: 14px; font-weight: 500; color: var(--ep-d-ink); }
.ep-expert .ep-aside .ep-contact-value a { color: var(--ep-d-ink); text-decoration: underline; text-decoration-color: var(--ep-d-leaf); text-underline-offset: 4px; }
.ep-expert .ep-aside .ep-contact-value a:hover { color: var(--ep-d-signal); }
.ep-expert .ep-aside .ep-login-btn { margin-left: 0 !important; }
.ep-expert .ep-aside .ep-tag { background: #fff; border-color: var(--ep-d-border); color: var(--ep-d-ink); }
.ep-expert .ep-aside .ep-tag a { color: inherit; text-decoration: none; }
.ep-expert .ep-aside .ep-tag:hover { border-color: var(--ep-d-leaf); }
.ep-expert .ep-aside .ep-address-body { color: var(--ep-d-muted-fg); }

@media (max-width: 991px) {
  .ep-expert .ep-hero { padding: 24px 0 36px; }
  .ep-expert .ep-hero-top { flex-direction: column; align-items: flex-start; text-align: left; gap: 24px; padding-top: 28px; }
  .ep-expert .ep-hero-actions { justify-content: flex-start; }
  .ep-expert .ep-name { font-size: 30px; }
  .ep-expert .ep-avatar-wrap, .ep-expert .ep-avatar-wrap img { max-width: 100%; }
}

/* ── Live-check fixes ───────────────────────────────────────── */
/* Theme breadcrumb is replaced by the one inside the hero */
body:has(.ep-expert) .breadcrumb-wrapper { display: none; }

/* Hero spans the full viewport width like the design */
.ep-expert .ep-hero {
  width: 100vw;
  margin-left: calc(50% - 50vw) !important;
  margin-right: 0;
}
.ep-expert .ep-body { margin-top: 0; }

/* Flat sections / aside panel: kill rounded corners from style.css */
.ep-expert .ep-section, .ep-expert .ep-card, .ep-expert .ep-aside > .ep-card { border-radius: 0 !important; }

/* ── More experts ───────────────────────────────────────────── */
.ep-expert .ep-more {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  background: var(--ep-d-leaf-soft);
  border-top: 1px solid var(--ep-d-border);
  padding: 48px 0;
}
.ep-expert .ep-more-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.ep-expert .ep-more-head h2 { margin: 0; font-size: 24px; font-weight: 600; color: var(--ep-d-ink); }
.ep-expert .ep-more-all { font-size: 14px; font-weight: 500; color: var(--ep-d-ink); text-decoration: none; }
.ep-expert .ep-more-all:hover { color: var(--ep-d-signal); }
.ep-expert .ep-more-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin-top: 28px; }
.ep-expert .ep-more-card {
  display: flex; align-items: flex-start; gap: 16px; padding: 20px;
  background: #fff; border: 1px solid var(--ep-d-border); border-radius: 8px;
  text-decoration: none; color: var(--ep-d-ink);
  transition: box-shadow .2s, transform .2s;
}
.ep-expert .ep-more-card:hover { box-shadow: 0 10px 30px -12px rgba(22,58,64,.3); transform: translateY(-2px); }
.ep-expert .ep-more-card img, .ep-expert .ep-more-initials { width: 64px; height: 64px; flex-shrink: 0; border-radius: 50%; object-fit: cover; }
.ep-expert .ep-more-initials { display: flex; align-items: center; justify-content: center; background: var(--ep-d-ink-soft); color: #fff; font-weight: 700; font-size: 24px; }
.ep-expert .ep-more-info { min-width: 0; }
.ep-expert .ep-more-info h3 { margin: 0; font-size: 16px; font-weight: 600; }
.ep-expert .ep-more-card:hover h3 { color: var(--ep-d-signal); }
.ep-expert .ep-more-role { margin: 4px 0 0; font-size: 12px; line-height: 1.5; color: var(--ep-d-signal); }
.ep-expert .ep-more-org { margin: 8px 0 0; font-size: 12px; line-height: 1.5; color: var(--ep-d-muted-fg); }
.ep-expert .ep-more-link { display: inline-flex; align-items: center; gap: 8px; margin-top: 12px; font-size: 12px; font-weight: 600; }
@media (max-width: 991px) { .ep-expert .ep-more-grid { grid-template-columns: 1fr; } }

/* ── Attach "More experts" to the footer ────────────────────── */
.region--content:has(.ep-more), .block-system-main-block:has(.ep-more) { margin-bottom: 0; padding-bottom: 0; }
.ep-expert .ep-body { padding-bottom: 48px; }

/* ── Knowledge Assets cards ─────────────────────────────────── */
.ep-expert .ep-asset-card {
  display: flex; flex-direction: column; height: 100%;
  background: #fff; border: 1px solid var(--ep-d-border); border-radius: 8px;
  overflow: hidden; text-decoration: none; color: var(--ep-d-ink);
  transition: box-shadow .2s, transform .2s;
}
.ep-expert .ep-asset-card:hover { box-shadow: 0 10px 30px -12px rgba(22,58,64,.3); transform: translateY(-2px); }
.ep-expert .ep-asset-thumb {
  aspect-ratio: 3 / 4; background: var(--ep-d-muted);
  display: flex; align-items: center; justify-content: center;
  color: var(--ep-d-muted-fg); font-size: 28px; overflow: hidden;
}
.ep-expert .ep-asset-thumb img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; }
.ep-expert .ep-asset-title {
  margin: 0; padding: 12px; font-size: 14px; font-weight: 600; line-height: 1.4;
  color: var(--ep-d-ink); text-align: left;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.ep-expert .ep-asset-card:hover .ep-asset-title { color: var(--ep-d-signal); }

/* ── Associated Institute(s) ────────────────────────────────── */
.ep-expert .ep-aside > .ep-institute .ep-section-body { padding: 8px 0 0; }
.ep-expert .ep-institute .row { align-items: center; row-gap: 12px; }
.ep-expert .ep-institute .expert-card-image {
  background: #fff; border: 1px solid var(--ep-d-border); border-radius: 8px;
  padding: 8px; display: flex; align-items: center; justify-content: center;
}
.ep-expert .ep-institute .expert-card-image img { max-width: 100%; max-height: 56px; width: auto; height: auto; object-fit: contain; }
.ep-expert .ep-institute .expert-card-title { margin: 0; font-size: 15px; font-weight: 600; line-height: 1.4; }
.ep-expert .ep-institute .expert-card-title a { color: var(--ep-d-ink); text-decoration: underline; text-decoration-color: var(--ep-d-leaf); text-underline-offset: 4px; }
.ep-expert .ep-institute .expert-card-title a:hover { color: var(--ep-d-signal); }

/* 100vw full-bleed bands include the vertical scrollbar width and cause a
   horizontal scrollbar; clip (not hidden) keeps the sticky header working. */
html:has(.ep-expert), body:has(.ep-expert) { overflow-x: clip; }

/* Empty light strip left behind once the theme breadcrumb is hidden */
body:has(.ep-expert) .page-header { display: none; }
