/* ics-card.css (P22) - ONE global card text alignment.
 * Rule: inside a card that has a photo / initials box, every text line (name, role, description)
 * starts at the photo's left edge and ends at its right edge (text inset = photo inset = 0).
 * Only horizontal padding/margin of the text block changes. Hover, flip and xcard behaviour untouched.
 * Tokens: change here only. */
:root {
  --ics-card-text-inset: 0px;  /* text block horizontal inset inside a card with a photo (left = right) */
  --ics-card-chip-inset: 0px;  /* plain role text (no pill background) horizontal inset */
}

/* 1. Torn card (news, documents, jobs, places, library, related): body text shares the photo edges */
/* tear-guard.css first-card and grid rules tie on id count; extra classes here (.nw-card.nw-card, .nw-cb x3) out-rank them. Grid ids listed 3x each. */
html body :is(
  #news-grid-home#news-grid-home#news-grid-home,
  #brxe-nwgrid#brxe-nwgrid#brxe-nwgrid,
  #wn-news-grid#wn-news-grid#wn-news-grid,
  #ab-news-grid#ab-news-grid#ab-news-grid,
  #mv-news-grid#mv-news-grid#mv-news-grid,
  #lib-grid#lib-grid#lib-grid,
  #brxe-dcgrid#brxe-dcgrid#brxe-dcgrid,
  #brxe-lggrd1#brxe-lggrd1#brxe-lggrd1,
  #brxe-rnl001#brxe-rnl001#brxe-rnl001,
  #brxe-rdl001#brxe-rdl001#brxe-rdl001,
  #brxe-rbl001#brxe-rbl001#brxe-rbl001,
  #brxe-rjl001#brxe-rjl001#brxe-rjl001,
  #brxe-evlp01#brxe-evlp01#brxe-evlp01
) .nw-card.nw-card:has(.ics-torn-photo) > .nw-cb.nw-cb.nw-cb,
html body .nw-card.nw-card:has(.ics-torn-photo) > .nw-cb.nw-cb.nw-cb {
  padding-left: var(--ics-card-text-inset) !important;
  padding-right: var(--ics-card-text-inset) !important;
}
html body :is(
  #news-grid-home#news-grid-home#news-grid-home,
  #brxe-nwgrid#brxe-nwgrid#brxe-nwgrid,
  #wn-news-grid#wn-news-grid#wn-news-grid,
  #ab-news-grid#ab-news-grid#ab-news-grid,
  #mv-news-grid#mv-news-grid#mv-news-grid,
  #lib-grid#lib-grid#lib-grid,
  #brxe-dcgrid#brxe-dcgrid#brxe-dcgrid,
  #brxe-lggrd1#brxe-lggrd1#brxe-lggrd1,
  #brxe-rnl001#brxe-rnl001#brxe-rnl001,
  #brxe-rdl001#brxe-rdl001#brxe-rdl001,
  #brxe-rbl001#brxe-rbl001#brxe-rbl001,
  #brxe-rjl001#brxe-rjl001#brxe-rjl001,
  #brxe-evlp01#brxe-evlp01#brxe-evlp01
) .nw-card.nw-card:has(.ics-torn-photo) > .nw-cb.nw-cb.nw-cb > :not(.ics-torn-photo),
html body .nw-card.nw-card:has(.ics-torn-photo) > .nw-cb.nw-cb.nw-cb > :not(.ics-torn-photo) {
  margin-left: 0 !important;
  margin-right: 0 !important;
  max-width: 100% !important;
  box-sizing: border-box;
}
html body .nw-card:has(.ics-torn-photo) .nw-tit.nw-tit,
html body .nw-card:has(.ics-torn-photo) .nw-cb .nw-chip.nw-chip {
  overflow-wrap: anywhere;
  min-width: 0;
}

/* 2. Flip card (advisors, bio): the front face already carries the gutter that the photo uses,
 *    so the name block adds no horizontal inset of its own. */
html body .ics-flip .nw-cb.nw-cb {
  padding-left: var(--ics-card-text-inset) !important;
  padding-right: var(--ics-card-text-inset) !important;
}
html body .ics-flip .nw-cb .nw-tit.nw-tit {
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  text-indent: 0 !important;
  overflow-wrap: anywhere;
}
/* advisor role chips carry per-card id rules in tear-guard.css (#adv-N-role); id-scoped override, 3 ids each. */
html body :is(
  #adv-1-role#adv-1-role#adv-1-role,
  #adv-2-role#adv-2-role#adv-2-role,
  #adv-3-role#adv-3-role#adv-3-role,
  #adv-4-role#adv-4-role#adv-4-role,
  #adv-5-role#adv-5-role#adv-5-role,
  #adv-6-role#adv-6-role#adv-6-role,
  #adv-7-role#adv-7-role#adv-7-role,
  #adv-8-role#adv-8-role#adv-8-role,
  #adv-9-role#adv-9-role#adv-9-role,
  #adv-10-role#adv-10-role#adv-10-role,
  #adv-11-role#adv-11-role#adv-11-role,
  #adv-12-role#adv-12-role#adv-12-role
),
html body .ics-flip .nw-cb .nw-chip.nw-chip,
html body .ics-flip .nw-cb .tm-role.tm-role {
  padding-left: var(--ics-card-chip-inset) !important;
  padding-right: var(--ics-card-chip-inset) !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  text-indent: 0 !important;
  white-space: normal !important;
  overflow-wrap: anywhere;
  max-width: 100%;
}

/* H123 C24 (2026-11-11, Figma sticker 2136:19594): news archive cards lose the grey stroke around the image (the grey torn ring = .ics-torn-photo::before). The white mat (::after) stays. Scope .nw-card (archive template 1095 + EN twin 2907). */
html body .nw-card.nw-card .ics-torn-photo.ics-torn-photo::before, html body .nw-card.nw-card .ics-torn-photo.ics-torn-photo:is(div,figure)::before { display: none !important; content: none !important; background: none !important; -webkit-mask: none !important; mask: none !important; }
