/* ==========================================================================
   Member List block
   ========================================================================== */

/* --- Base list (single-column default) --- */
.member-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	gap: 2rem;
}

.member-list > li {
	margin: 0;
	padding: 0;
}

/* --- Content typography --- */
.member-list__content > :first-child {
	margin-top: 0;
}

.member-list__content h2,
.member-list__content h3,
.member-list__content h4,
.member-list__content h5,
.member-list__content h6 {
	margin-bottom: 0.25rem;
}

.member-list p {
	margin: 0 0 5px 0;
}
#content .member-list h2{
	margin-bottom:10px;
}

.member-list__degrees {
	margin: 0.5rem 0;
	padding-left: 1.25rem;
}

.member-list__degrees li {
	margin: 0.15rem 0;
}

.member-list__additional {
	margin-top: 0.5rem;
	opacity: 0.9;
}

.member-list__address {
	font-style: normal;
	line-height: 1.4;
}

.member-list__email a,
.member-list__phone a {
	word-break: break-word;
}

/* --- Member image --- */
.member-list__image {
	display: block;
	max-width: 100%;
	height: auto;
}

.member-list__media {
	margin-bottom: 1rem;
}
.member-list__media[aria-hidden="true"] {
	margin-bottom: 0;
}

/* ==========================================================================
   Two-column variant (image left, content right)
   ========================================================================== */

/* Block container: bordered grid. Dividers are drawn with cell borders, so
   gap is 0. */
ul.member-list.wp-block-umsv-member-list {
	display: grid;
	gap: 0;
	margin: 0;
	padding: 0;
	list-style: none;
	padding-left: 0;
	border: 1px solid var(--brand-color-dark-blue);
}

/* Row divider only.
   IMPORTANT: do NOT set align-items or justify-content here. The grid rows
   must keep their default `stretch`, which is what makes both columns equal
   height and lets the vertical divider run the full height of the row. */
ul.member-list.wp-block-umsv-member-list > li {
	margin: 0;
	padding: 18px;
	gap: 0;
	border-bottom: 1px solid var(--brand-color-dark-blue);
	list-style: none;
}
ul.member-list.wp-block-umsv-member-list > li:last-child{
	border-bottom:0;
}
ul.member-list.wp-block-umsv-member-list > li:nth-child(odd) {
	background-color: #f7fafa;
}

ul.member-list.wp-block-umsv-member-list .member-list__content h2 a,
ul.member-list.wp-block-umsv-member-list .member-list__content h3 a{
	line-height:1.44;
}
@media only screen and (max-width:767px){
	ul.member-list.wp-block-umsv-member-list .member-list__content h2,
	ul.member-list.wp-block-umsv-member-list .member-list__content h3,
	ul.member-list.wp-block-umsv-member-list .member-list__content h2 a,
	ul.member-list.wp-block-umsv-member-list .member-list__content h3 a{
		font-size:24px !important;
	}
}

/* Image cell + the full-height vertical divider.
   The divider lives here (not on the content cell) so that members with no
   image — which omit .member-list__media entirely — simply have no divider. */
ul.member-list.is-two-column.wp-block-umsv-member-list .member-list__media {
	padding: 30px;
	margin-bottom: 0;
	max-width: 100%;
	border-right: 1px solid var(--brand-color-dark-blue);
}

/* Content cell */
ul.member-list.is-two-column.wp-block-umsv-member-list .member-list__content {
	padding: 30px;
	min-width: 0;
	display: flex;
	flex-direction: column;
	justify-content: center;
}

ul.member-list.is-two-column.wp-block-umsv-member-list img {
	display: block;
	margin: 0;
	padding: 0;
}

/* Turn each row into a 2-track grid — but ONLY when a media element exists,
   so members with no image let the content fill the full width.
   Equal-height columns are automatic here: grid items default to
   align-items: stretch.
   NOTE: this assumes the block omits .member-list__media when there is no
   image. If it instead renders an empty media wrapper, replace :has() with a
   server-side class such as li.has-media. */
.member-list.is-two-column > li:has(.member-list__media) {
	display: grid;
	grid-template-columns: 200px 1fr;
}

/* ==========================================================================
   Visually-hidden labels for screen readers (e.g. "Contact Email:").
   Uses the clip technique — never display:none, which would also hide the
   text from assistive technology. Scoped to the block so it can't clash with
   a theme's own .screen-reader-text definition.
   ========================================================================== */
.member-list .screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	border: 0;
	overflow: hidden;
	clip: rect(1px, 1px, 1px, 1px);
	clip-path: inset(50%);
	white-space: nowrap;
	word-wrap: normal !important;
}
/* --- Stack on narrow screens --- */
@media (max-width: 600px) {
	.member-list.is-two-column > li:has(.member-list__media) {
		grid-template-columns: 1fr;
	}

	/* Image is now on top, so move its divider from right to bottom.
	   Same selector as the base media rule, so this simply overrides it. */
	ul.member-list.is-two-column.wp-block-umsv-member-list .member-list__media {
		padding: 18px 18px 0 18px;
		border-right: 0;
	}
	ul.member-list.is-two-column img{
		max-width:130px;
	} 
	ul.member-list.is-two-column.wp-block-umsv-member-list .member-list__content {
		padding: 18px;
	}
}