/* =====================================================================
   EDS Core – Programs + Program Details widgets (EDS Academy)
   Scope ":not(#eds)" = ID-level specificity (theme link styles can't leak in).
   ===================================================================== */

.eds-pg,.eds-pd{
	--cols:3;
	--ink:var(--e-global-color-secondary,#111);
	--muted:var(--e-global-color-eds_g600,#737373);
	--rule:var(--e-global-color-46313f9,#e5e5e5);
	--surface:var(--e-global-color-4b5c478,#f5f5f5);
	--ease:cubic-bezier(.2,.7,.2,1);
	--in:cubic-bezier(.7,0,.12,1);
}
@media (max-width:1024px){.eds-pg{--cols:2}}
@media (max-width:767px){.eds-pg{--cols:1}}
.eds-pg:not(#eds){margin:0;padding:0;list-style:none}
.eds-pg:not(#eds) li{margin:0;padding:0}

/* ---------- Badge ---------- */
.eds-pg:not(#eds) .eds-pg__badge,.eds-pd:not(#eds) .eds-pd__badge{
	display:inline-flex;align-items:center;gap:8px;padding:5px 12px;border-radius:999px;background:#fff;color:#000;
	font-size:.6875rem;font-weight:700;letter-spacing:.1em;text-transform:uppercase;line-height:1.4;white-space:nowrap;
}
.eds-pg:not(#eds) .eds-pg__badge--upcoming::before,.eds-pd:not(#eds) .eds-pd__badge--upcoming::before{
	content:"";width:6px;height:6px;border-radius:50%;background:currentColor;animation:eds-pg-pulse 2.4s ease-in-out infinite;
}
.eds-pg:not(#eds) .eds-pg__badge--previous,.eds-pd:not(#eds) .eds-pd__badge--previous{background:#000;color:#fff}
@keyframes eds-pg-pulse{0%,100%{opacity:1}50%{opacity:.25}}

/* ---------- List (upcoming): date | text | photo | arrow ---------- */
.eds-pg--list:not(#eds){border-top:1px solid var(--rule)}
.eds-pg--list:not(#eds) .eds-pg__row{border-bottom:1px solid var(--rule)}
.eds-pg--list:not(#eds) .eds-pg__link{
	position:relative;display:grid;grid-template-columns:132px minmax(0,1fr) 240px 56px;align-items:center;gap:var(--eds-gap-l,40px);
	padding:32px 0;color:var(--ink);text-decoration:none;
}
.eds-pg--list:not(#eds) .eds-pg__link::before{
	content:"";position:absolute;inset:0 calc(var(--eds-gutter,40px) * -.5);z-index:-1;border-radius:20px;background:var(--surface);
	opacity:0;transform:scaleY(.92);transition:opacity .5s var(--ease),transform .6s var(--in);
}
.eds-pg--list:not(#eds) .eds-pg__link:is(:hover,:focus-visible)::before{opacity:1;transform:none}
.eds-pg--list:not(#eds) .eds-pg__link:focus-visible{outline:2px solid var(--ink);outline-offset:4px;border-radius:12px}
.eds-pg--list:not(#eds) .eds-pg__row{position:relative;z-index:0}

.eds-pg:not(#eds) .eds-pg__date time{display:flex;align-items:flex-start;gap:12px}
.eds-pg:not(#eds) .eds-pg__day{font-family:var(--e-global-typography-primary-font-family,inherit),sans-serif;font-size:clamp(2.75rem,4.5vw,4rem);font-weight:400;line-height:.9;letter-spacing:-.03em;font-variant-numeric:tabular-nums}
.eds-pg:not(#eds) .eds-pg__sr{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}
.eds-pg:not(#eds) .eds-pg__my > span{display:block}
.eds-pg:not(#eds) .eds-pg__my{padding-top:4px;color:var(--muted);font-size:.8125rem;font-weight:700;letter-spacing:.12em;line-height:1.35;text-transform:uppercase}

.eds-pg--list:not(#eds) .eds-pg__main{display:flex;flex-direction:column;gap:10px;min-width:0}
.eds-pg:not(#eds) .eds-pg__meta{display:flex;flex-wrap:wrap;align-items:center;gap:8px 12px;color:var(--muted);font-size:.8125rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase;line-height:1.4}
.eds-pg--list:not(#eds) .eds-pg__badge{border:1px solid var(--rule)}
.eds-pg:not(#eds) .eds-pg__title{font-family:var(--e-global-typography-primary-font-family,inherit),sans-serif;font-size:var(--e-global-typography-eds_h3-font-size,1.875rem);font-weight:400;line-height:1.2;letter-spacing:-.01em}
.eds-pg:not(#eds) .eds-pg__speaker{color:var(--ink);font-size:.9375rem;font-weight:700}
.eds-pg:not(#eds) .eds-pg__desc{max-width:62ch;color:var(--muted);font-size:.9375rem;line-height:1.55}

.eds-pg--list:not(#eds) .eds-pg__thumb{display:block;overflow:hidden;border-radius:16px;aspect-ratio:4/3;background:var(--surface)}
.eds-pg:not(#eds) .eds-pg__img{display:block;width:100%;height:100%;max-width:none;object-fit:cover;filter:grayscale(1);transform:scale(1.001);transition:transform .9s var(--ease),filter .9s var(--ease)}
.eds-pg--list:not(#eds) .eds-pg__link:is(:hover,:focus-visible) .eds-pg__img{filter:grayscale(0);transform:scale(1.05)}

.eds-pg--list:not(#eds) .eds-pg__go{
	display:grid;place-items:center;width:56px;height:56px;border:1px solid var(--rule);border-radius:50%;color:var(--ink);
	transition:background-color .45s var(--ease),border-color .45s var(--ease),color .45s var(--ease);
}
/* The arrow turns around its own centre: the rotation sits on the path, in the
   16×16 viewBox whose centre (8,8) is the arrow's centre. No translate. */
.eds-pg--list:not(#eds) .eds-pg__go svg{display:block;width:16px;height:16px;overflow:visible;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}
.eds-pg--list:not(#eds) .eds-pg__go path{transform-box:view-box;transform-origin:50% 50%;transition:transform .5s var(--ease)}
.eds-pg--list:not(#eds) .eds-pg__link:is(:hover,:focus-visible) .eds-pg__go{background:var(--ink);border-color:var(--ink);color:#fff}
.eds-pg--list:not(#eds) .eds-pg__link:is(:hover,:focus-visible) .eds-pg__go path{transform:rotate(-45deg)}
.eds-pg:not(#eds) .eds-pg__title{overflow-wrap:anywhere;text-wrap:balance}
.eds-pg:not(#eds) .eds-pg__desc{text-wrap:pretty}

/* Narrower desktops: smaller photo, tighter gaps. */
@media (max-width:1280px){
	.eds-pg--list:not(#eds) .eds-pg__link{grid-template-columns:116px minmax(0,1fr) 200px 52px;gap:32px}
	.eds-pg--list:not(#eds) .eds-pg__go{width:52px;height:52px}
}
/* Tablet: date | text, photo on the right; the whole row is the link. */
@media (max-width:1024px){
	.eds-pg--list:not(#eds) .eds-pg__link{grid-template-columns:96px minmax(0,1fr) minmax(150px,30%);gap:20px 28px;padding:28px 0}
	.eds-pg--list:not(#eds) .eds-pg__link::before{inset:0 -16px}
	.eds-pg--list:not(#eds) .eds-pg__go{display:none}
	.eds-pg:not(#eds) .eds-pg__day{font-size:3rem}
	.eds-pg:not(#eds) .eds-pg__desc{display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
}
/* Phone: photo first, then a date line, then the text. */
@media (max-width:767px){
	.eds-pg--list:not(#eds) .eds-pg__link{grid-template-columns:minmax(0,1fr);gap:14px;padding:24px 0 28px}
	.eds-pg--list:not(#eds) .eds-pg__link::before{display:none}
	.eds-pg--list:not(#eds) .eds-pg__thumb{order:-1;aspect-ratio:16/9;border-radius:14px}
	.eds-pg--list:not(#eds) .eds-pg__img{filter:none}
	.eds-pg:not(#eds) .eds-pg__date time{align-items:baseline;gap:10px}
	.eds-pg:not(#eds) .eds-pg__day{font-size:2.25rem}
	.eds-pg:not(#eds) .eds-pg__my > span{display:inline}
	.eds-pg:not(#eds) .eds-pg__my{padding:0}
	.eds-pg:not(#eds) .eds-pg__title{font-size:1.375rem}
	.eds-pg--list:not(#eds) .eds-pg__main{gap:8px}
}

/* ---------- Cards (previous) ---------- */
.eds-pg--cards:not(#eds){display:grid;grid-template-columns:repeat(var(--cols),minmax(0,1fr));gap:var(--eds-gap-l,48px) var(--eds-gap-m,24px)}
.eds-pg--cards:not(#eds) .eds-pg__card{display:flex;flex-direction:column;gap:20px;height:100%;color:var(--ink);text-decoration:none}
.eds-pg--cards:not(#eds) .eds-pg__media{position:relative;display:block;overflow:hidden;border-radius:20px;aspect-ratio:4/3;background:var(--surface)}
.eds-pg--cards:not(#eds) .eds-pg__card:is(:hover,:focus-visible) .eds-pg__img{transform:scale(1.04);filter:grayscale(0)}
.eds-pg--cards:not(#eds) .eds-pg__badge{position:absolute;top:14px;left:14px}
.eds-pg--cards:not(#eds) .eds-pg__extras{position:absolute;right:14px;bottom:14px;padding:5px 12px;border-radius:999px;background:rgba(0,0,0,.6);-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);color:#fff;font-size:.75rem;font-weight:700;letter-spacing:.04em}
.eds-pg--cards:not(#eds) .eds-pg__body{display:flex;flex-direction:column;gap:8px;padding:0 2px;flex:1}
.eds-pg--cards:not(#eds) .eds-pg__title{font-size:var(--e-global-typography-eds_h4-font-size,1.375rem);font-family:inherit;font-weight:700;line-height:1.3;letter-spacing:0}
.eds-pg--cards:not(#eds) .eds-pg__more{
	align-self:flex-start;display:inline-flex;align-items:center;gap:10px;margin-top:auto;padding-top:8px;padding-bottom:3px;font-size:.9375rem;font-weight:700;
	background:linear-gradient(currentColor,currentColor) 0 100%/0 1px no-repeat;transition:background-size .45s var(--ease);
}
.eds-pg--cards:not(#eds) .eds-pg__more svg{width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;transition:transform .45s var(--ease)}
.eds-pg--cards:not(#eds) .eds-pg__card:is(:hover,:focus-visible) .eds-pg__more{background-size:100% 1px}
.eds-pg--cards:not(#eds) .eds-pg__card:is(:hover,:focus-visible) .eds-pg__more svg{transform:translateX(4px)}
.eds-pg--cards:not(#eds) .eds-pg__card:focus-visible{outline:2px solid var(--ink);outline-offset:6px;border-radius:20px}
.eds-pg-empty{margin:0;padding:24px;border:1px dashed var(--e-global-color-46313f9,#e5e5e5);border-radius:12px;color:var(--e-global-color-eds_g600,#737373)}

/* =====================================================================
   Program details (single program template)
   ===================================================================== */
.eds-pd:not(#eds){display:flex;flex-direction:column;gap:var(--eds-gap-l,48px)}
.eds-pd:not(#eds) :is(p,h2,h3,dl,dd,dt,ul){margin:0;padding:0}

/* Badge line */
.eds-pd--badge:not(#eds){flex-direction:row;flex-wrap:wrap;align-items:center;gap:12px}
.eds-pd--badge:not(#eds) .eds-pd__badge{border:1px solid var(--rule)}
.eds-pd--badge:not(#eds) .eds-pd__badge--previous{border-color:#000}
.eds-pd:not(#eds) .eds-pd__when{color:var(--muted);font-size:.8125rem;font-weight:700;letter-spacing:.12em;text-transform:uppercase}

/* Facts strip */
.eds-pd:not(#eds) .eds-pd__facts{display:grid;grid-template-columns:repeat(auto-fit,minmax(170px,1fr));border-top:1px solid var(--rule);border-bottom:1px solid var(--rule)}
.eds-pd:not(#eds) .eds-pd__fact{padding:24px 24px 24px 0}
.eds-pd:not(#eds) .eds-pd__fact + .eds-pd__fact{padding-left:24px;border-left:1px solid var(--rule)}
.eds-pd:not(#eds) .eds-pd__fact dt{margin:0 0 8px;color:var(--muted);font-size:.75rem;font-weight:700;letter-spacing:.12em;text-transform:uppercase}
.eds-pd:not(#eds) .eds-pd__fact dd{color:var(--ink);font-size:1.0625rem;line-height:1.4}
@media (max-width:767px){
	.eds-pd:not(#eds) .eds-pd__facts{grid-template-columns:1fr 1fr}
	.eds-pd:not(#eds) .eds-pd__fact,.eds-pd:not(#eds) .eds-pd__fact + .eds-pd__fact{padding:18px 12px 18px 0;border-left:0}
	.eds-pd:not(#eds) .eds-pd__fact:nth-child(even){padding-left:16px;border-left:1px solid var(--rule)}
	.eds-pd:not(#eds) .eds-pd__fact:nth-child(n+3){border-top:1px solid var(--rule)}
}

.eds-pd:not(#eds) .eds-pd__pdf{align-self:flex-start}
.eds-pd:not(#eds) .eds-pd__h{margin:0 0 24px;color:var(--ink);font-family:var(--e-global-typography-primary-font-family,inherit),sans-serif;font-size:var(--e-global-typography-eds_h3-font-size,1.875rem);font-weight:400;line-height:1.2;letter-spacing:-.01em}

/* Faculty */
.eds-pd:not(#eds) .eds-pd__faculty{display:flex;flex-direction:column;gap:12px;list-style:none}
.eds-pd:not(#eds) .eds-pd__person{display:grid;grid-template-columns:72px minmax(0,1fr);align-items:center;gap:16px;padding:12px;border-radius:16px;background:#fff;border:1px solid var(--rule)}
.eds-pd:not(#eds) .eds-pd__face{display:block;width:72px;height:72px;overflow:hidden;border-radius:12px;background:var(--surface)}
.eds-pd:not(#eds) .eds-pd__init{display:grid;place-items:center;width:100%;height:100%;color:var(--ink);font-size:1.25rem;letter-spacing:.04em}
.eds-pd:not(#eds) .eds-pd__face img{display:block;width:100%;height:100%;max-width:none;object-fit:cover;object-position:50% 20%}
.eds-pd:not(#eds) .eds-pd__who{display:flex;flex-direction:column;gap:4px;min-width:0}
.eds-pd:not(#eds) .eds-pd__name{color:var(--ink);font-size:1.0625rem;font-weight:700;line-height:1.3}
.eds-pd:not(#eds) .eds-pd__role{color:var(--muted);font-size:.875rem;line-height:1.4}
.eds-pd:not(#eds) .eds-pd__who .eds-pf-btn{align-self:flex-start;margin-top:4px;font-size:.8125rem}

/* Video + gallery */
.eds-pd:not(#eds) .eds-pd__video{position:relative;aspect-ratio:16/9;border-radius:20px;overflow:hidden;background:#000}
.eds-pd:not(#eds) .eds-pd__video iframe{position:absolute;inset:0;width:100%;height:100%;border:0}
.eds-pd:not(#eds) .eds-pd__gallery{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));grid-auto-flow:dense;gap:var(--eds-gap-s,16px);list-style:none}
.eds-pd:not(#eds) .eds-pd__gallery li{grid-column:span 2}
.eds-pd:not(#eds) .eds-pd__gallery li:nth-child(5n+1){grid-column:span 4;grid-row:span 2}
.eds-pd:not(#eds) .eds-pd__gallery a{display:block;height:100%;min-height:160px;overflow:hidden;border-radius:16px;aspect-ratio:4/3}
.eds-pd:not(#eds) .eds-pd__gallery li:nth-child(5n+1) a{aspect-ratio:auto}
.eds-pd:not(#eds) .eds-pd__gallery img{display:block;width:100%;height:100%;max-width:none;object-fit:cover;transition:transform .9s var(--ease)}
.eds-pd:not(#eds) .eds-pd__gallery a:is(:hover,:focus-visible) img{transform:scale(1.04)}
@media (max-width:767px){
	.eds-pd:not(#eds) .eds-pd__gallery{grid-template-columns:repeat(2,minmax(0,1fr))}
	.eds-pd:not(#eds) .eds-pd__gallery li,.eds-pd:not(#eds) .eds-pd__gallery li:nth-child(5n+1){grid-column:span 1;grid-row:auto}
	.eds-pd:not(#eds) .eds-pd__gallery li:nth-child(3n+1){grid-column:span 2}
	.eds-pd:not(#eds) .eds-pd__gallery a,.eds-pd:not(#eds) .eds-pd__gallery li:nth-child(5n+1) a{min-height:0;aspect-ratio:4/3}
}

@media (prefers-reduced-motion:reduce){
	.eds-pg:not(#eds) *,.eds-pd:not(#eds) *{transition-duration:.01ms !important;animation:none !important}
}
