#e365-recent-epc {
  --ink: #032357;
  --edge: #d5e2ea;
  margin: 0;
  padding: clamp(28px,4vw,56px) 0;
  background: white;
  color: var(--ink);
  --recent-heading-font: Montserrat, Arial, Helvetica, sans-serif;
  --recent-body-font: "helvetica-neue", Montserrat, Arial, Helvetica, sans-serif;
  --recent-section-size: 38px;
  --recent-tracking: -.022em;
  font-family: var(--recent-body-font);
}
.e365-home-v2 #e365-recent-epc {
  --recent-section-size: var(--e365-h2);
  --recent-heading-font: Montserrat, sans-serif;
  --recent-tracking: -.026em;
}
.e365-projects #e365-recent-epc {
  --recent-section-size: var(--e365-type-h2);
  --recent-heading-font: Montserrat, sans-serif;
  --recent-tracking: -.025em;
}
@media (min-width:850px) and (max-width:1199px) {
  .energy365-epcc-shell #e365-recent-epc { --recent-section-size: clamp(29px,3.027vw,38px); }
}
@media (max-width:849px) {
  .energy365-epcc-shell #e365-recent-epc { --recent-section-size: clamp(26px,7vw,29px); }
}
@media (max-width:720px) {
  .e365-projects #e365-recent-epc { --recent-section-size: 28px; --recent-section-leading: 1.16; }
}
#e365-recent-epc *, #e365-recent-epc *::after { box-sizing: border-box; }
#e365-recent-epc .epc-cards-shell { width: min(100% - 40px,1180px); margin: auto; }
#e365-recent-epc .epc-cards-heading {
  margin: 0 0 clamp(14px,2vw,24px); color: var(--ink); text-transform: none;
  font: 800 var(--recent-section-size)/var(--recent-section-leading,1.15) var(--recent-heading-font); letter-spacing: var(--recent-tracking);
}
#e365-recent-epc .epc-cards-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: clamp(14px,2vw,26px); }
#e365-recent-epc .epc-project {
  position: relative; display: flex; flex-direction: column; overflow: hidden;
  height: 100%; border-radius: 8px; border: 1px solid var(--edge);
  text-align: left; text-decoration: none; background: white; color: var(--ink);
}
#e365-recent-epc .epc-project-photo { display: block; position: relative; overflow: hidden; background: #d9e5ec; }
#e365-recent-epc .epc-project-photo img {
  display: block; width: 100%; height: auto; aspect-ratio: 2.65; object-fit: cover; object-position: center 48%;
  margin: 0; border: 0; border-radius: 0; opacity: 1;
}
#e365-recent-epc .epc-project-year {
  position: absolute; z-index: 1; left: 0; bottom: 0; padding: 5px 15px 5px 12px;
  border-left: 4px solid #47b2e4; background: #032357; color: white;
  font-variant-numeric: tabular-nums;
}
#e365-recent-epc .epc-project-copy { display: flex; flex-direction: column; flex: 1; padding: clamp(15px,1.8vw,24px); }
#e365-recent-epc .epc-project-location { color: #37566b; margin-bottom: 6px; }
#e365-recent-epc .epc-project-name {
  margin: 0 0 6px; color: var(--ink); text-transform: none; letter-spacing: normal;
}
#e365-recent-epc .epc-project-scope { color: #41566a; }
#e365-recent-epc .epc-project-action {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; color: var(--ink);
  border-top: 1px solid var(--edge); padding: 10px 0 0; margin: 18px 0 0;
}
#e365-recent-epc .epc-project-arrow { display:grid; place-items:center; width:28px; height:28px; border-radius:50%; background:#e7f4fa; color:var(--ink); font: 500 18px/1 Arial,sans-serif; }
#e365-recent-epc .epc-project:focus-visible { outline: 3px solid #09658c; outline-offset: 3px; }
#e365-recent-epc .epc-project:is(:hover,:focus-visible) { border-color: #6f99b3; }
#e365-recent-epc .epc-project:is(:hover,:focus-visible) .epc-project-arrow { background:var(--ink); color:white; }
@media (max-width:640px) {
  #e365-recent-epc .epc-cards-grid { grid-template-columns: 1fr; gap:16px; }
  #e365-recent-epc .epc-project-photo img { aspect-ratio: 2.7; }
  #e365-recent-epc .epc-project-action { margin-top:12px; }
}

#e365-recent-epc .recent-heading-row { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:clamp(16px,2vw,24px); }
#e365-recent-epc .recent-heading-row .epc-cards-heading { margin:0; font-size:var(--recent-section-size); }
#e365-recent-epc .recent-controls { display:flex; align-items:center; gap:6px; }
#e365-recent-epc .recent-controls[hidden] { display:none; }
#e365-recent-epc .recent-controls button {
  display:grid; place-items:center; width:40px; height:40px; min-height:0; margin:0; padding:0;
  border:1px solid var(--edge); border-radius:50%; background:white; color:var(--ink);
  font:600 18px/1 Arial,sans-serif; cursor:pointer; box-shadow:none; letter-spacing:0;
}
#e365-recent-epc .recent-controls button[data-play] { color:white; background:var(--ink); border-color:var(--ink); font-size:14px; }
#e365-recent-epc .recent-controls button:focus-visible { outline:3px solid #09658c; outline-offset:2px; }
#e365-recent-epc[data-loop] .recent-viewport { overflow:hidden; padding:5px; margin:-5px; touch-action:pan-y pinch-zoom; }
#e365-recent-epc[data-loop] .epc-cards-grid { --gap:20px; --shown:3; display:flex; align-items:stretch; gap:var(--gap); }
#e365-recent-epc[data-loop] .epc-project {
  flex:0 0 calc((100% - (var(--shown) - 1) * var(--gap)) / var(--shown)); height:auto; min-width:0;
}
#e365-recent-epc .epc-project-photo img { aspect-ratio:2; }
#e365-recent-epc .epc-project-capacity { margin-top:4px; margin-bottom:auto; }
@media(max-width:959px){ #e365-recent-epc[data-loop] .epc-cards-grid { --shown:2; --gap:16px; } }
@media(max-width:639px){
  #e365-recent-epc[data-loop] .epc-cards-grid { --shown:1; }
  #e365-recent-epc .recent-controls { gap:4px; }
  #e365-recent-epc .recent-controls button { width:36px; height:36px; }
  #e365-recent-epc .recent-controls { flex-shrink:0; }
}
#e365-recent-epc [data-play]::before { content:""; width:9px; height:12px; border:solid white; border-width:0 3px; box-sizing:border-box; }
#e365-recent-epc [data-play][data-paused=true]::before { width:0; height:0; margin-left:2px; border-width:6px 0 6px 9px; border-color:transparent transparent transparent white; }

@media (max-width:359px) {
  #e365-recent-epc .recent-heading-row { flex-wrap:wrap; }
}

/* Names and profile actions share a type scale across the three project layouts. */
#main {
  --project-card-type: Montserrat, Arial, Helvetica, sans-serif;
  --project-card-name-size: 18px;
}
@media (max-width:849px) {
  #main { --project-card-name-size: 17px; }
}
#main :is(
  section[aria-labelledby="e365-project-title"] .e365-project-caption > strong,
  #featured-projects .e365-featured-card__body h3,
  #featured-projects .e365-featured-card__body h3 > a.e365-project-link,
  #epcc-projects .e365-featured-case__intro h3 + p,
  #epcc-projects .e365-case-row__identity > strong,
  #epcc-projects .e365-case-preview figcaption > strong,
  #e365-recent-epc .epc-project-name
) {
  font: 800 var(--project-card-name-size)/1.34 var(--project-card-type);
  letter-spacing: normal;
  text-transform: none;
}
#main :is(
  section[aria-labelledby="e365-project-title"] .e365-project-head .e365-text-link,
  #featured-projects .e365-section-head > a,
  #featured-projects .e365-card-foot > a.e365-project-link,
  #epcc-projects .e365-featured-case__intro p > a,
  #epcc-projects a.e365-project-link,
  #e365-recent-epc .epc-project-action
) {
  font: 700 13.5px/1.35 var(--project-card-type);
  letter-spacing: normal;
  text-transform: none;
}
/* The site's CTA layer also targets links inside featured card headings. */
#main #featured-projects .e365-featured-card__body h3 > a.e365-project-link {
  font: inherit !important;
}
#main .e365-project-head .e365-text-link,
#main #featured-projects .e365-section-head > a {
  line-height: 1.35 !important;
}

/* Portfolio facts use the same size in captions, cards and case summaries. */
#main :is(
  section[aria-labelledby="e365-project-title"] .e365-project-caption > span,
  #featured-projects .e365-featured-card__body > p,
  #epcc-projects .e365-case-row__meta > small,
  #epcc-projects .e365-case-preview figcaption > small,
  #epcc-projects .e365-featured-case__story p,
  #e365-recent-epc .epc-project-location,
  #e365-recent-epc .epc-project-scope,
  #e365-recent-epc .epc-project-capacity
) {
  font: 400 14px/1.6 var(--project-card-type);
  letter-spacing: normal;
}
#main :is(
  #e365-recent-epc .epc-project-year,
  #epcc-projects .e365-featured-case__metrics strong
) {
  font: 700 14px/1.45 var(--project-card-type);
  letter-spacing: normal;
}
/* The theme forces its body font on portfolio paragraphs. */
#main #featured-projects .e365-featured-card__body > p {
  font-family: var(--project-card-type) !important;
}
