/* Shared styles of the Image Hero, Story Chapters and Logo Wall content blocks.
   Plain CSS on purpose: the blocks load it through f:asset.css, so a change here needs no CDN build. */

.dgm-ih,
.dgm-sc,
.dgm-lw {
  --sb-primary: var(--primary, #25af40);
  --sb-ink: #0f172a;
  --sb-text: #475569;
  --sb-line: rgba(15, 23, 42, 0.08);
  --sb-radius: 24px;
  --sb-wrap: 1280px;
  --sb-gutter: clamp(1.25rem, 4vw, 2.5rem);
  color: var(--sb-ink);
}

/* Shared pieces */

.dgm-sb-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  padding: 0.375rem 0.75rem;
  border: 1px solid color-mix(in srgb, var(--sb-primary) 30%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--sb-primary) 6%, #fff);
  color: var(--sb-primary);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  line-height: 1.3;
  text-transform: uppercase;
}

.dgm-sb-prose {
  color: var(--sb-text);
  font-size: 1.0625rem;
  line-height: 1.7;
  overflow-wrap: anywhere;
}

.dgm-sb-prose > * + * {
  margin-top: 1em;
}

.dgm-sb-prose h3,
.dgm-sb-prose h4 {
  margin-top: 1.75em;
  color: var(--sb-ink);
  font-family: "Heading-Font", Theme-Font, Inter, system-ui, sans-serif;
  font-size: 1.1875rem;
  font-weight: 650;
  letter-spacing: -0.01em;
  line-height: 1.35;
}

.dgm-sb-prose strong {
  color: var(--sb-ink);
  font-weight: 600;
}

.dgm-sb-prose ul,
.dgm-sb-prose ol {
  display: grid;
  gap: 0.6em;
  padding-left: 1.25em;
}

.dgm-sb-prose ul {
  list-style: disc;
}

.dgm-sb-prose ol {
  list-style: decimal;
}

.dgm-sb-prose li::marker {
  color: var(--sb-primary);
  font-weight: 600;
}

.dgm-sb-prose a {
  color: var(--sb-primary);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.dgm-sb-prose a:hover {
  text-decoration-thickness: 2px;
}

.dgm-sb-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2rem;
}

.dgm-sb-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.625rem;
  padding: 0.8125rem 1.375rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

.dgm-sb-btn:hover {
  transform: translateY(-1px);
}

.dgm-sb-btn--primary {
  background: var(--sb-primary);
  box-shadow: 0 10px 24px -12px var(--sb-primary);
  color: #fff;
}

.dgm-sb-btn--secondary {
  border-color: var(--sb-line);
  background: #fff;
  color: var(--sb-ink);
}

.dgm-sb-btn--secondary:hover {
  border-color: var(--sb-primary);
}

.dgm-sb-btn--ghost {
  background: transparent;
  color: var(--sb-primary);
}

/* Image Hero */

.dgm-ih {
  padding: 0 var(--sb-gutter);
}

.dgm-ih--bleed {
  padding: 0;
}

.dgm-ih__frame {
  position: relative;
  display: flex;
  overflow: hidden;
  max-width: var(--sb-wrap);
  margin: 0 auto;
  border-radius: var(--sb-radius);
  background: #0b1f17;
  isolation: isolate;
}

.dgm-ih--bleed .dgm-ih__frame {
  max-width: none;
  border-radius: 0;
}

.dgm-ih--h-compact .dgm-ih__frame { min-height: 320px; }
.dgm-ih--h-medium .dgm-ih__frame { min-height: min(62vh, 560px); }
.dgm-ih--h-tall .dgm-ih__frame { min-height: min(78vh, 720px); }
.dgm-ih--h-viewport .dgm-ih__frame { min-height: 100svh; }

.dgm-ih__media {
  position: absolute;
  z-index: -2;
  inset: 0;
}

.dgm-ih__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dgm-ih__body {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  width: 100%;
  max-width: 46rem;
  padding: clamp(2rem, 5vw, 4rem);
}

.dgm-ih--t-center .dgm-ih__body {
  align-items: center;
  margin: 0 auto;
  text-align: center;
}

.dgm-ih--t-right .dgm-ih__body {
  align-items: flex-end;
  margin-left: auto;
  text-align: right;
}

.dgm-ih__title {
  margin: 1rem 0 0;
  color: #fff;
  font-size: clamp(2.25rem, 5vw, 3.75rem);
  font-weight: 750;
  letter-spacing: -0.025em;
  line-height: 1.05;
  text-wrap: balance;
}

.dgm-ih__sub {
  margin: 0.875rem 0 0;
  color: rgba(255, 255, 255, 0.95);
  font-size: clamp(1.125rem, 2vw, 1.5rem);
  font-weight: 550;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.dgm-ih__lead {
  margin-top: 1rem;
  color: rgba(255, 255, 255, 0.88);
  font-size: 1.0625rem;
  line-height: 1.65;
}

.dgm-ih__lead > * + * {
  margin-top: 0.75em;
}

.dgm-ih .dgm-sb-eyebrow {
  border-color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  backdrop-filter: blur(8px);
}

.dgm-ih--overlay .dgm-ih__frame::before {
  position: absolute;
  z-index: -1;
  background: linear-gradient(90deg, rgba(4, 18, 13, 0.82) 0%, rgba(4, 18, 13, 0.55) 45%, rgba(4, 18, 13, 0.08) 100%);
  content: "";
  inset: 0;
}

.dgm-ih--overlay.dgm-ih--t-center .dgm-ih__frame::before {
  background: linear-gradient(180deg, rgba(4, 18, 13, 0.3) 0%, rgba(4, 18, 13, 0.72) 100%);
}

.dgm-ih--overlay.dgm-ih--t-right .dgm-ih__frame::before {
  background: linear-gradient(270deg, rgba(4, 18, 13, 0.82) 0%, rgba(4, 18, 13, 0.55) 45%, rgba(4, 18, 13, 0.08) 100%);
}

.dgm-ih--overlay.dgm-ih--s-primary .dgm-ih__frame::before {
  background: linear-gradient(90deg, color-mix(in srgb, var(--sb-primary), #000 58%) 0%, color-mix(in srgb, var(--sb-primary), #000 62%) 42%, rgba(0, 0, 0, 0.05) 100%);
}

.dgm-ih--overlay.dgm-ih--s-light .dgm-ih__frame::before {
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.94) 0%, rgba(255, 255, 255, 0.78) 45%, rgba(255, 255, 255, 0.05) 100%);
}

.dgm-ih--s-light .dgm-ih__title,
.dgm-ih--s-light .dgm-ih__sub {
  color: var(--sb-ink);
}

.dgm-ih--s-light .dgm-ih__lead {
  color: var(--sb-text);
}

.dgm-ih--s-light .dgm-sb-eyebrow {
  border-color: color-mix(in srgb, var(--sb-primary) 30%, transparent);
  background: rgba(255, 255, 255, 0.7);
  color: var(--sb-primary);
}

.dgm-ih--card .dgm-ih__body {
  align-self: flex-end;
  max-width: 34rem;
  margin: clamp(1rem, 3vw, 2.5rem);
  padding: clamp(1.5rem, 3vw, 2.5rem);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(18px) saturate(140%);
}

.dgm-ih--card .dgm-ih__title,
.dgm-ih--card .dgm-ih__sub {
  color: var(--sb-ink);
}

.dgm-ih--card .dgm-ih__lead {
  color: var(--sb-text);
}

.dgm-ih--card .dgm-sb-eyebrow {
  border-color: color-mix(in srgb, var(--sb-primary) 30%, transparent);
  background: #fff;
  color: var(--sb-primary);
}

.dgm-ih--split .dgm-ih__frame {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  background: transparent;
}

.dgm-ih--split .dgm-ih__media {
  position: relative;
  z-index: 0;
  order: 2;
  overflow: hidden;
  border-radius: var(--sb-radius);
}

.dgm-ih--split .dgm-ih__img {
  position: absolute;
  inset: 0;
}

.dgm-ih--split .dgm-ih__body {
  justify-content: center;
  max-width: none;
  padding: clamp(1.5rem, 4vw, 3rem) clamp(1.5rem, 4vw, 4rem) clamp(1.5rem, 4vw, 3rem) 0;
}

.dgm-ih--split .dgm-ih__title,
.dgm-ih--split .dgm-ih__sub {
  color: var(--sb-ink);
}

.dgm-ih--split .dgm-ih__lead {
  color: var(--sb-text);
}

.dgm-ih--split .dgm-sb-eyebrow {
  border-color: color-mix(in srgb, var(--sb-primary) 30%, transparent);
  background: color-mix(in srgb, var(--sb-primary) 6%, #fff);
  color: var(--sb-primary);
}

/* Image Hero, layout immersive. The muted film sits below two pairs of lenses: the tint layer recolours it, the glow
   layer lifts it, so inside the circles the footage turns vivid while it stays gray outside. */

/* 100vw counts a classic scrollbar, which would add a sideways scroll. clip keeps sticky elements working, hidden would not. */
html:has(.dgm-lh),
body:has(.dgm-lh) {
  overflow-x: clip;
}

.dgm-lh {
  --sb-primary: var(--primary, #25af40);
  position: relative;
  display: flex;
  overflow: hidden;
  align-items: center;
  justify-content: center;
  width: 100vw;
  min-height: max(100svh, 40rem);
  margin-left: calc(50% - 50vw);
  background: #071510;
  color: #fff;
  isolation: isolate;
}

.dgm-lh__stage,
.dgm-lh__poster,
.dgm-lh__video,
.dgm-lh__shade,
.dgm-lh__network,
.dgm-lh__vignette {
  position: absolute;
  inset: 0;
}

.dgm-lh__stage {
  z-index: -1;
  overflow: hidden;
  isolation: isolate;
}

.dgm-lh__poster,
.dgm-lh__video {
  width: 100%;
  height: 100%;
  background-position: center;
  background-size: cover;
  filter: grayscale(1) brightness(0.72) contrast(1.12);
  object-fit: cover;
}

.dgm-lh__video {
  opacity: 0;
  transition: opacity 1.2s ease;
}

.dgm-lh.has-video .dgm-lh__video {
  opacity: 1;
}

.dgm-lh__shade {
  background: rgba(6, 22, 16, 0.3);
}

.dgm-lh__lens {
  position: absolute;
  top: 0;
  left: 0;
  border-radius: 50%;
  pointer-events: none;
  will-change: transform;
}

.dgm-lh__lens--tint {
  mix-blend-mode: color;
}

.dgm-lh__lens--glow {
  mix-blend-mode: soft-light;
}

.dgm-lh__lens--a.dgm-lh__lens--tint {
  background: radial-gradient(circle closest-side, var(--dgm-lh-a, #3cf022) 0 66%, transparent 100%);
}

.dgm-lh__lens--b.dgm-lh__lens--tint {
  background: var(--dgm-lh-b, #2bb6ff);
}

.dgm-lh__lens--a.dgm-lh__lens--glow {
  background: radial-gradient(circle closest-side, #fff 0 62%, rgba(255, 255, 255, 0) 100%);
  mix-blend-mode: overlay;
}

.dgm-lh__lens--b.dgm-lh__lens--glow {
  background: #fff;
}

.dgm-lh__overlap {
  overflow: hidden;
}

.dgm-lh__overlap--tint {
  mix-blend-mode: color;
}

.dgm-lh__overlap--shade {
  mix-blend-mode: multiply;
}

.dgm-lh__overlap-shape {
  position: absolute;
  border-radius: 50%;
  inset: 0;
}

.dgm-lh__overlap--tint .dgm-lh__overlap-shape {
  background: radial-gradient(circle closest-side, var(--sb-primary) 0 66%, transparent 100%);
}

.dgm-lh__overlap--shade .dgm-lh__overlap-shape {
  background: radial-gradient(circle closest-side, rgba(10, 90, 40, 0.62) 0 66%, rgba(10, 90, 40, 0) 100%);
}

.dgm-lh__network {
  width: 100%;
  height: 100%;
}

.dgm-lh__vignette {
  background:
    radial-gradient(ellipse 58% 44% at 50% 52%, rgba(4, 14, 10, 0.62) 0%, rgba(4, 14, 10, 0) 100%),
    linear-gradient(180deg, rgba(4, 14, 10, 0.55) 0%, rgba(4, 14, 10, 0) 22%, rgba(4, 14, 10, 0) 72%, rgba(4, 14, 10, 0.6) 100%);
}

.dgm-lh__content {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: min(100%, 68rem);
  padding: 7rem 1.5rem 6rem;
  text-align: center;
  will-change: transform, opacity;
}

.dgm-lh__notice {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  margin-bottom: 1.75rem;
  padding: 0.5rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  background: rgba(6, 22, 16, 0.42);
  color: #fff;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.3;
  text-decoration: none;
  backdrop-filter: blur(12px);
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.dgm-lh__notice:hover {
  border-color: rgba(255, 255, 255, 0.55);
  background: rgba(6, 22, 16, 0.62);
}

.dgm-lh__notice i {
  font-size: 0.75em;
  transition: transform 0.2s ease;
}

.dgm-lh__notice:hover i {
  transform: translateX(3px);
}

.dgm-lh__notice-dot {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: #5dda4a;
  box-shadow: 0 0 0 0 rgba(93, 218, 74, 0.7);
  animation: dgm-lh-ping 2.4s ease-out infinite;
}

.dgm-lh__title {
  margin: 0;
  color: #fff;
  font-size: clamp(2.75rem, 8.2vw, 7.5rem);
  font-weight: 750;
  letter-spacing: -0.035em;
  line-height: 0.98;
  text-shadow: 0 2px 40px rgba(4, 14, 10, 0.55);
}

.dgm-lh__accent {
  display: block;
  margin-top: 0.08em;
  filter: drop-shadow(0 2px 14px rgba(4, 14, 10, 0.7));
}

.dgm-lh__accent .dgm-lh__char {
  background-image: linear-gradient(100deg, #e2ffda, #c9f0ff);
  background-repeat: no-repeat;
  background-clip: text;
  color: transparent;
  text-shadow: none;
  -webkit-background-clip: text;
}

.dgm-lh__word {
  display: inline-block;
  white-space: nowrap;
}

.dgm-lh__char {
  display: inline-block;
  opacity: 0;
  filter: blur(10px);
  transform: translateY(0.42em) rotate(4deg);
}

.dgm-lh.is-live .dgm-lh__char {
  animation: dgm-lh-char 0.9s cubic-bezier(0.2, 0.8, 0.2, 1) calc(0.5s + var(--i) * 34ms) forwards;
}

.dgm-lh__lines {
  display: grid;
  margin: 1.5rem 0 0;
  color: rgba(255, 255, 255, 0.94);
  font-size: clamp(1.0625rem, 2vw, 1.5rem);
  font-weight: 500;
  letter-spacing: -0.005em;
  line-height: 1.35;
  text-shadow: 0 1px 20px rgba(4, 14, 10, 0.6);
}

.dgm-lh__line {
  grid-area: 1 / 1;
  opacity: 0;
  transform: translateY(0.5rem);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.dgm-lh__line.is-active {
  opacity: 1;
  transform: none;
}

.dgm-lh__lead {
  max-width: 44rem;
  margin-top: 1rem;
  color: rgba(255, 255, 255, 0.86);
  font-size: 1.0625rem;
  line-height: 1.6;
}

.dgm-lh__buttons {
  justify-content: center;
}

.dgm-lh .dgm-sb-btn--primary {
  background: #fff;
  box-shadow: 0 14px 34px -16px rgba(0, 0, 0, 0.6);
  color: #0b2a1a;
}

.dgm-lh .dgm-sb-btn--secondary {
  border-color: rgba(255, 255, 255, 0.4);
  background: rgba(6, 22, 16, 0.32);
  color: #fff;
  backdrop-filter: blur(12px);
}

.dgm-lh .dgm-sb-btn--secondary:hover {
  border-color: #fff;
}

.dgm-lh__notice,
.dgm-lh__lines,
.dgm-lh__lead,
.dgm-lh__buttons,
.dgm-lh__cue {
  opacity: 0;
}

.dgm-lh.is-live .dgm-lh__notice { animation: dgm-lh-rise 0.8s ease 0.25s forwards; }
.dgm-lh.is-live .dgm-lh__lines { animation: dgm-lh-rise 0.8s ease 1.15s forwards; }
.dgm-lh.is-live .dgm-lh__lead { animation: dgm-lh-rise 0.8s ease 1.3s forwards; }
.dgm-lh.is-live .dgm-lh__buttons { animation: dgm-lh-rise 0.8s ease 1.45s forwards; }
.dgm-lh.is-live .dgm-lh__cue { animation: dgm-lh-rise 0.8s ease 2s forwards; }

/* Without the script the text must still appear. */
.dgm-lh:not(.is-live) .dgm-lh__char,
.dgm-lh:not(.is-live) .dgm-lh__notice,
.dgm-lh:not(.is-live) .dgm-lh__lines,
.dgm-lh:not(.is-live) .dgm-lh__lead,
.dgm-lh:not(.is-live) .dgm-lh__buttons {
  animation: dgm-lh-rise 0.6s ease 3.5s forwards;
}

.dgm-lh:not(.is-live) .dgm-lh__title {
  animation: dgm-lh-rise 0.6s ease 3.5s both;
}

.dgm-lh:not(.is-live) .dgm-lh__line:first-child {
  opacity: 1;
}

.dgm-lh__toggle {
  position: absolute;
  right: 1.5rem;
  bottom: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 50%;
  background: rgba(6, 22, 16, 0.42);
  color: #fff;
  cursor: pointer;
  font-size: 0.8125rem;
  backdrop-filter: blur(12px);
  transition: border-color 0.2s ease;
}

.dgm-lh__toggle:hover,
.dgm-lh__toggle:focus-visible {
  border-color: #fff;
}

.dgm-lh__cue {
  position: absolute;
  bottom: 1.75rem;
  left: 50%;
  width: 1.5rem;
  height: 2.375rem;
  margin-left: -0.75rem;
  border: 1.5px solid rgba(255, 255, 255, 0.6);
  border-radius: 999px;
}

.dgm-lh__cue span {
  position: absolute;
  top: 0.4rem;
  left: 50%;
  width: 3px;
  height: 0.5rem;
  margin-left: -1.5px;
  border-radius: 2px;
  background: #fff;
  animation: dgm-lh-cue 2s ease-in-out infinite;
}

@keyframes dgm-lh-char {
  to {
    opacity: 1;
    filter: blur(0);
    transform: none;
  }
}

@keyframes dgm-lh-rise {
  from {
    opacity: 0;
    transform: translateY(0.75rem);
  }

  to {
    opacity: 1;
    filter: none;
    transform: none;
  }
}

@keyframes dgm-lh-ping {
  70%,
  100% {
    box-shadow: 0 0 0 0.625rem rgba(93, 218, 74, 0);
  }
}

@keyframes dgm-lh-cue {
  0% { opacity: 0; transform: translateY(0); }
  30% { opacity: 1; }
  100% { opacity: 0; transform: translateY(0.75rem); }
}

@media (max-width: 767px) {
  .dgm-lh__content {
    padding: 6.5rem 1.25rem 5.5rem;
  }

  .dgm-lh__title {
    font-size: clamp(2.5rem, 12.2vw, 4rem);
  }

  .dgm-lh__buttons {
    flex-direction: column;
    align-items: stretch;
    width: min(100%, 20rem);
  }

  .dgm-lh__notice {
    font-size: 0.8125rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .dgm-lh__char,
  .dgm-lh__notice,
  .dgm-lh__lines,
  .dgm-lh__lead,
  .dgm-lh__buttons,
  .dgm-lh__cue,
  .dgm-lh.is-live .dgm-lh__char,
  .dgm-lh.is-live .dgm-lh__notice,
  .dgm-lh.is-live .dgm-lh__lines,
  .dgm-lh.is-live .dgm-lh__lead,
  .dgm-lh.is-live .dgm-lh__buttons,
  .dgm-lh.is-live .dgm-lh__cue {
    opacity: 1;
    filter: none;
    transform: none;
    animation: none;
  }

  .dgm-lh__notice-dot,
  .dgm-lh__cue span {
    animation: none;
  }

  .dgm-lh__toggle {
    display: none;
  }
}

/* Story Chapters */

.dgm-sc {
  padding: clamp(3rem, 7vw, 6rem) var(--sb-gutter);
}

/* The band reaches the window edges without changing the layout width, so no horizontal scrollbar can appear. */
.dgm-sc--tone-light,
.dgm-sc--tone-tint,
.dgm-sc--tone-dark {
  background: var(--sb-band);
  box-shadow: 0 0 0 100vmax var(--sb-band);
  clip-path: inset(0 -100vmax);
}

.dgm-sc--tone-light {
  --sb-band: #f4f6f8;
}

.dgm-sc--tone-tint {
  --sb-band: color-mix(in srgb, var(--sb-primary) 6%, #fff);
}

.dgm-sc--tone-dark {
  --sb-band: #0b1f17;
  --sb-ink: #fff;
  --sb-text: rgba(255, 255, 255, 0.78);
  --sb-line: rgba(255, 255, 255, 0.14);
}

.dgm-sc__wrap {
  max-width: var(--sb-wrap);
  margin: 0 auto;
}

.dgm-sc__head {
  max-width: 48rem;
  margin: 0 0 clamp(2rem, 4vw, 3.5rem);
}

.dgm-sc__head--center {
  margin-right: auto;
  margin-left: auto;
  text-align: center;
}

.dgm-sc__head--center .dgm-sc__title {
  text-align: center;
}

/* The block opens the page: the breadcrumb above it already gives enough air. */
.dgm-sc:has(.dgm-sc__title--page) {
  padding-top: clamp(1rem, 2.5vw, 2rem);
}

.dgm-sc:has(.dgm-sc__title--page) .dgm-sc__head {
  margin-bottom: clamp(1.5rem, 3vw, 2.5rem);
}

.dgm-sc__title {
  margin: 0.875rem 0 0;
  color: var(--sb-ink);
  font-size: clamp(1.75rem, 3.2vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  text-wrap: balance;
}

.dgm-sc__title--page {
  font-size: clamp(2.5rem, 6vw, 4.25rem);
  letter-spacing: -0.03em;
  line-height: 1.04;
}

.dgm-sc--editorial .dgm-sc__title {
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  line-height: 1.2;
}

/* Used as a plain page heading, without chapters below it. */
.dgm-sc--headonly {
  padding-bottom: 0;
}

.dgm-sc--headonly .dgm-sc__rows {
  display: none;
}

.dgm-sc--headonly .dgm-sc__head,
.dgm-sc--headonly:has(.dgm-sc__title--page) .dgm-sc__head {
  margin-bottom: 0;
}

.dgm-sc--headonly .dgm-sc__title--page {
  font-size: clamp(2.25rem, 4.5vw, 3.25rem);
}

.dgm-sc__subtitle {
  margin: 0.75rem 0 0;
  color: var(--sb-text);
  font-size: clamp(1.0625rem, 1.8vw, 1.3125rem);
  font-weight: 500;
  line-height: 1.4;
}

.dgm-sc__intro {
  margin-top: 1rem;
}

.dgm-sc__kicker {
  display: flex;
  align-items: baseline;
  gap: 0.625rem;
  margin: 0;
  color: var(--sb-primary);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  line-height: 1.4;
  text-transform: uppercase;
}

.dgm-sc__number {
  display: none;
}

.dgm-sc--numbered .dgm-sc__number {
  display: inline;
  opacity: 0.55;
}

.dgm-sc__chapter-title {
  margin: 0.625rem 0 0;
  color: var(--sb-ink);
  font-size: clamp(1.375rem, 2.3vw, 1.875rem);
  font-weight: 700;
  letter-spacing: -0.018em;
  line-height: 1.2;
  text-wrap: balance;
}

.dgm-sc__chapter-body {
  margin-top: 0.875rem;
}

.dgm-sc__more {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.125rem;
  color: var(--sb-primary);
  font-size: 0.9375rem;
  font-weight: 600;
  text-decoration: none;
}

.dgm-sc__more i {
  font-size: 0.8125em;
  transition: transform 0.2s ease;
}

.dgm-sc__more:hover i {
  transform: translateX(3px);
}

.dgm-sc__media {
  position: relative;
  overflow: hidden;
  border-radius: var(--sb-radius);
  background: #e7ecef;
}

.dgm-sc__media::after {
  position: absolute;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px var(--sb-line);
  content: "";
  inset: 0;
  pointer-events: none;
}

.dgm-sc__img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dgm-sc--r-16-9 .dgm-sc__media { aspect-ratio: 16 / 9; }
.dgm-sc--r-3-2 .dgm-sc__media { aspect-ratio: 3 / 2; }
.dgm-sc--r-4-3 .dgm-sc__media { aspect-ratio: 4 / 3; }
.dgm-sc--r-1-1 .dgm-sc__media { aspect-ratio: 1 / 1; }

.dgm-sc--r-auto .dgm-sc__media {
  aspect-ratio: auto;
}

.dgm-sc--r-auto .dgm-sc__img {
  height: auto;
}

/* Layout: image panels */

.dgm-sc--panels {
  padding-top: clamp(1.5rem, 3vw, 2.5rem);
  padding-bottom: clamp(0.5rem, 1.5vw, 1rem);
}

.dgm-sc__head:not(:has(*)) {
  display: none;
}

.dgm-sc__panels {
  display: grid;
  gap: clamp(1.25rem, 3vw, 2.5rem);
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Image and caption share one grid cell, so a long caption makes the panel taller instead of being cut off. */
.dgm-sc__panel {
  position: relative;
  display: grid;
  overflow: hidden;
  border-radius: var(--sb-radius);
  background: #0b1f17;
  box-shadow: 0 30px 60px -38px rgba(15, 23, 42, 0.55);
}

.dgm-sc__panel .dgm-sc__media {
  grid-area: 1 / 1;
  min-height: 100%;
  border-radius: 0;
  aspect-ratio: 16 / 9;
}

.dgm-sc__caption {
  z-index: 1;
  grid-area: 1 / 1;
  align-self: end;
  justify-self: start;
  width: min(30rem, calc(100% - 2rem));
  margin: clamp(1rem, 2.5vw, 2rem);
  padding: clamp(1.25rem, 2.2vw, 1.875rem);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 16px 40px -24px rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(18px) saturate(150%);
}

.dgm-sc--first-right .dgm-sc__panel:nth-child(odd) .dgm-sc__caption,
.dgm-sc--first-left .dgm-sc__panel:nth-child(even) .dgm-sc__caption {
  justify-self: end;
}

.dgm-sc__caption .dgm-sc__chapter-title {
  font-size: clamp(1.25rem, 2vw, 1.625rem);
}

.dgm-sc__caption .dgm-sb-prose {
  font-size: 1rem;
  line-height: 1.6;
}

/* Layout: mosaic. One large tile, then a wide one every fifth tile, so eleven tiles fill four rows exactly. */

.dgm-sc__mosaic {
  display: grid;
  grid-auto-flow: dense;
  grid-auto-rows: clamp(11rem, 17vw, 15rem);
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(0.625rem, 1.2vw, 1rem);
  margin: 0;
  padding: 0;
  list-style: none;
}

.dgm-sc__tile {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  background: #0b1f17;
  isolation: isolate;
}

.dgm-sc__tile:first-child {
  grid-column: span 2;
  grid-row: span 2;
}

.dgm-sc__tile:nth-child(5n + 6) {
  grid-column: span 2;
}

.dgm-sc__tile .dgm-sc__img {
  position: absolute;
  z-index: -2;
  transition: transform 0.6s ease;
  inset: 0;
}

.dgm-sc__tile:hover .dgm-sc__img {
  transform: scale(1.05);
}

.dgm-sc__tile::after {
  position: absolute;
  z-index: -1;
  background: linear-gradient(180deg, rgba(4, 18, 13, 0) 45%, rgba(4, 18, 13, 0.78) 100%);
  content: "";
  inset: 0;
}

.dgm-sc__tile-text {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  padding: clamp(0.875rem, 1.6vw, 1.25rem);
  color: #fff;
}

.dgm-sc__tile-kicker {
  margin: 0 0 0.25rem;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.dgm-sc__tile-title {
  margin: 0;
  color: #fff;
  font-size: clamp(1rem, 1.5vw, 1.25rem);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.2;
}

.dgm-sc__tile:first-child .dgm-sc__tile-title {
  font-size: clamp(1.5rem, 2.6vw, 2.25rem);
}

.dgm-sc__tile-link {
  color: inherit;
  text-decoration: none;
}

.dgm-sc__tile-link::after {
  position: absolute;
  content: "";
  inset: 0;
}

/* Layout: alternating rows */

.dgm-sc__rows {
  display: grid;
  gap: clamp(2.5rem, 6vw, 5rem);
}

.dgm-sc__row {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(1.75rem, 5vw, 4.5rem);
}

.dgm-sc--first-left .dgm-sc__row:nth-child(even) .dgm-sc__media,
.dgm-sc--first-right .dgm-sc__row:nth-child(odd) .dgm-sc__media {
  order: 2;
}

.dgm-sc--first-left .dgm-sc__row:nth-child(even),
.dgm-sc--first-right .dgm-sc__row:nth-child(odd) {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr);
}

.dgm-sc__row--text {
  display: block;
  max-width: 48rem;
}

/* Layout: editorial */

.dgm-sc__editorial {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(1.75rem, 6vw, 5.5rem);
}

.dgm-sc--sticky .dgm-sc__aside-inner {
  position: sticky;
  top: 7rem;
}

.dgm-sc__editorial--figure {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.dgm-sc__main > .dgm-sb-prose {
  max-width: 42rem;
}

.dgm-sc__figure {
  display: block;
  overflow: hidden;
  margin-top: 1.5rem;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 0 0 1px var(--sb-line), 0 24px 48px -36px rgba(15, 23, 42, 0.5);
  cursor: zoom-in;
}

.dgm-sc__figure-img {
  display: block;
  width: 100%;
  height: auto;
  transition: transform 0.5s ease;
}

.dgm-sc__figure:hover .dgm-sc__figure-img {
  transform: scale(1.02);
}

.dgm-sc__notes {
  display: grid;
  gap: 2rem;
  margin-top: 2rem;
}

.dgm-sc__notes .dgm-sc__media {
  margin-bottom: 1rem;
}

/* Layout: cards */

.dgm-sc__cards {
  display: grid;
  gap: clamp(1rem, 2.2vw, 1.75rem);
  margin: 0;
  padding: 0;
  list-style: none;
}

.dgm-sc__cards--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.dgm-sc__cards--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.dgm-sc__cards--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.dgm-sc__card {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--sb-line);
  border-radius: 20px;
  background: #fff;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.dgm-sc--tone-dark .dgm-sc__card {
  background: rgba(255, 255, 255, 0.05);
}

.dgm-sc__card .dgm-sc__media {
  border-radius: 0;
}

.dgm-sc__card .dgm-sc__text {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 1.25rem 1.375rem 1.5rem;
}

.dgm-sc__card .dgm-sc__chapter-title {
  font-size: 1.1875rem;
  line-height: 1.3;
}

.dgm-sc__card .dgm-sb-prose {
  font-size: 0.9375rem;
  line-height: 1.6;
}

.dgm-sc__card .dgm-sc__more {
  margin-top: auto;
  padding-top: 1rem;
}

.dgm-sc__card--link:hover {
  box-shadow: 0 24px 48px -30px rgba(15, 23, 42, 0.45);
  transform: translateY(-3px);
}

.dgm-sc__card--link .dgm-sc__more::after {
  position: absolute;
  content: "";
  inset: 0;
}

.dgm-sc__card .dgm-sc__img {
  transition: transform 0.5s ease;
}

.dgm-sc__card--link:hover .dgm-sc__img {
  transform: scale(1.04);
}

/* Logo Wall */

.dgm-lw {
  padding: clamp(2.5rem, 5vw, 4.5rem) var(--sb-gutter);
}

.dgm-lw__wrap {
  max-width: var(--sb-wrap);
  margin: 0 auto;
}

.dgm-lw__head {
  max-width: 44rem;
  margin: 0 0 2rem;
}

.dgm-lw--align-center .dgm-lw__head {
  margin-right: auto;
  margin-left: auto;
  text-align: center;
}

.dgm-lw__title {
  margin: 0.75rem 0 0;
  color: var(--sb-ink);
  font-size: clamp(1.5rem, 2.6vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.dgm-lw__intro {
  margin-top: 0.75rem;
}

.dgm-lw__groups {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem clamp(1.5rem, 3vw, 2.5rem);
}

.dgm-lw--align-center .dgm-lw__groups {
  justify-content: center;
}

.dgm-lw__group {
  flex: var(--dgm-lw-count, 1) 1 calc(var(--dgm-lw-count, 1) * 11rem);
  min-width: 0;
}

.dgm-lw__group-title {
  margin: 0 0 0.875rem;
  color: var(--sb-text);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.dgm-lw__list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
  gap: 0.875rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.dgm-lw--row .dgm-lw__list {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 2rem;
}

.dgm-lw--row.dgm-lw--align-center .dgm-lw__list {
  justify-content: center;
}

.dgm-lw__tile {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: var(--dgm-lw-tile, 6.5rem);
  padding: 1rem 1.25rem;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.dgm-lw--tiles .dgm-lw__tile {
  border: 1px solid var(--sb-line);
  border-radius: 16px;
  background: #fff;
}

.dgm-lw--tiles a.dgm-lw__tile:hover {
  border-color: color-mix(in srgb, var(--sb-primary) 40%, transparent);
  box-shadow: 0 16px 30px -24px rgba(15, 23, 42, 0.5);
  transform: translateY(-2px);
}

.dgm-lw--small { --dgm-lw-tile: 5rem; --dgm-lw-logo: 2.25rem; }
.dgm-lw--medium { --dgm-lw-tile: 6.5rem; --dgm-lw-logo: 3.25rem; }
.dgm-lw--large { --dgm-lw-tile: 8.5rem; --dgm-lw-logo: 5.5rem; }

.dgm-lw__logo {
  display: block;
  width: auto;
  max-width: 100%;
  max-height: var(--dgm-lw-logo, 3.25rem);
  object-fit: contain;
}

.dgm-lw__name {
  color: var(--sb-ink);
  font-size: 0.9375rem;
  font-weight: 600;
  text-align: center;
}

.dgm-lw--row {
  padding-top: clamp(1.5rem, 3vw, 2.5rem);
  padding-bottom: clamp(1.5rem, 3vw, 2.5rem);
}

.dgm-lw--gray .dgm-lw__logo {
  filter: grayscale(1);
  opacity: 0.75;
  transition: filter 0.2s ease, opacity 0.2s ease;
}

.dgm-lw--gray a.dgm-lw__tile:hover .dgm-lw__logo {
  filter: none;
  opacity: 1;
}

/* The extra wide event header around the CRM widgets gets the same width and gutter as the blocks above. Without this,
   .container touches the window edge at its breakpoints and .frame adds an inset on smaller screens only. */
.dgm-ex-root > .container {
  --sb-gutter: clamp(1.25rem, 4vw, 2.5rem);
  max-width: calc(1280px + 2 * var(--sb-gutter));
  padding-right: var(--sb-gutter);
  padding-left: var(--sb-gutter);
}

.dgm-ex-root > .container .frame {
  padding-right: 0;
  padding-left: 0;
}

/* CRM calendar, layout 1, inside .dgm-events. The widget's markup comes from the shared bundle, so this only restyles it:
   if that markup changes, the calendar falls back to its normal look. Cards stack image and text; one or two events on
   a wide screen go side by side instead, so a short list still fills the row. */

.dgm-events {
  --sb-primary: var(--primary, #25af40);
  --sb-ink: #0f172a;
  --sb-text: #475569;
  --sb-line: rgba(15, 23, 42, 0.08);
}

.dgm-events .container {
  max-width: none;
  padding: 0;
}

.dgm-events .container > .grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 19rem), 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
}

.dgm-events .block.mb-6 {
  max-width: 24rem;
}

.dgm-events .container > .grid > a {
  overflow: hidden;
  border: 1px solid var(--sb-line);
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 18px 40px -34px rgba(15, 23, 42, 0.45);
  text-align: left;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.dgm-events .container > .grid > a:hover {
  border-color: color-mix(in srgb, var(--sb-primary) 35%, transparent);
  box-shadow: 0 26px 48px -32px rgba(15, 23, 42, 0.5);
  transform: translateY(-3px);
}

.dgm-events .container > .grid > a:only-child {
  max-width: 44rem;
}

.dgm-events .container > .grid > a > .absolute.z-0 {
  position: relative;
  flex: none;
  height: 13rem;
  border-radius: 0;
  opacity: 1;
  mask-image: none !important;
  -webkit-mask-image: none !important;
}

/* The chip repeats the date, so it only stays for status notices such as a cancellation. */
.dgm-events .container > .grid > a > .absolute.z-10:has(.fa-calendar-alt) {
  display: none;
}

.dgm-events .container > .grid > a > .absolute.z-10 {
  top: 0.875rem;
  left: 0.875rem;
  justify-content: flex-start;
  width: auto;
}

.dgm-events .container > .grid > a > .flex-1 {
  padding: 1.25rem 1.5rem 1.375rem;
}

.dgm-events .container > .grid > a > .flex-1::after {
  position: absolute;
  right: 1.375rem;
  bottom: 1.125rem;
  color: var(--sb-primary);
  content: "\2192";
  font-size: 1.125rem;
  line-height: 1;
  transition: transform 0.2s ease;
}

.dgm-events .container > .grid > a:hover > .flex-1::after {
  transform: translateX(3px);
}

.dgm-events .container > .grid > a.cursor-default > .flex-1::after {
  display: none;
}

.dgm-events .flex-1 > dl {
  flex-grow: 0;
  order: -1;
  justify-content: flex-start;
  margin: 0 0 0.625rem;
}

.dgm-events .flex-1 > dl dd {
  color: var(--sb-primary);
  font-size: 0.8125rem;
  font-weight: 600;
  line-height: 1.4;
}

.dgm-events .flex-1 > h3:nth-of-type(2) {
  margin: 0;
  color: var(--sb-ink);
  font-family: "Heading-Font", Theme-Font, Inter, system-ui, sans-serif;
  font-size: clamp(1.125rem, 1.6vw, 1.3125rem);
  letter-spacing: -0.015em;
  line-height: 1.25;
  text-wrap: balance;
}

.dgm-events .flex-1 > h3:nth-of-type(2) > div {
  display: none;
}

.dgm-events .flex-1 > h4 {
  margin: 0.5rem 0 0;
  color: var(--sb-text);
  font-size: 0.9375rem;
  line-height: 1.5;
}

.dgm-events .flex-1 > h3:first-child {
  order: 3;
  margin: auto 0 0;
  padding-top: 0.875rem;
  padding-right: 2rem;
  color: var(--sb-text);
  font-size: 0.8125rem;
  font-weight: 500;
}

.dgm-events .container > .grid > li {
  border: 1px dashed var(--sb-line);
  border-radius: 20px;
  background: transparent;
  min-height: 8rem;
}

@media (min-width: 1024px) {
  .dgm-events .container > .grid:not(:has(> :nth-child(3))) > a {
    flex-direction: row;
  }

  .dgm-events .container > .grid:not(:has(> :nth-child(3))) > a > .absolute.z-0 {
    flex: 0 0 48%;
    height: auto;
    min-height: 12.5rem;
  }
}

/* Tablet and below */

@media (max-width: 1023px) {
  .dgm-sc__editorial {
    grid-template-columns: minmax(0, 1fr);
  }

  .dgm-sc--sticky .dgm-sc__aside-inner {
    position: static;
  }

  .dgm-sc__editorial--figure {
    grid-template-columns: minmax(0, 1fr);
  }

  .dgm-sc__cards--3,
  .dgm-sc__cards--4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dgm-ih--split .dgm-ih__frame {
    grid-template-columns: minmax(0, 1fr);
  }

  .dgm-ih--split .dgm-ih__media {
    order: 0;
    min-height: 16rem;
  }

  .dgm-ih--split .dgm-ih__body {
    padding: 1.5rem 0 0;
  }
}

/* Phone */

@media (max-width: 767px) {
  .dgm-ih__title,
  .dgm-sc__title,
  .dgm-sc__chapter-title {
    hyphens: auto;
    overflow-wrap: break-word;
  }

  .dgm-ih--overlay .dgm-ih__frame::before {
    background: linear-gradient(180deg, rgba(4, 18, 13, 0.25) 0%, rgba(4, 18, 13, 0.82) 100%);
  }

  .dgm-sc__row,
  .dgm-sc--first-left .dgm-sc__row:nth-child(even),
  .dgm-sc--first-right .dgm-sc__row:nth-child(odd) {
    grid-template-columns: minmax(0, 1fr);
  }

  .dgm-sc--first-left .dgm-sc__row:nth-child(even) .dgm-sc__media,
  .dgm-sc--first-right .dgm-sc__row:nth-child(odd) .dgm-sc__media {
    order: 0;
  }

  .dgm-sc__cards--2,
  .dgm-sc__cards--3,
  .dgm-sc__cards--4 {
    grid-template-columns: minmax(0, 1fr);
  }

  .dgm-sc__panel {
    display: block;
    background: #fff;
    box-shadow: none;
    border: 1px solid var(--sb-line);
  }

  .dgm-sc__panel .dgm-sc__media {
    min-height: 0;
  }

  .dgm-sc__caption,
  .dgm-sc--first-right .dgm-sc__panel:nth-child(odd) .dgm-sc__caption,
  .dgm-sc--first-left .dgm-sc__panel:nth-child(even) .dgm-sc__caption {
    width: auto;
    margin: 0;
    border-radius: 0;
    background: #fff;
    box-shadow: none;
    backdrop-filter: none;
  }

  .dgm-sc__mosaic {
    grid-auto-rows: 9.5rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dgm-lw__group {
    flex-basis: 100%;
  }

  .dgm-lw__list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Sticky stacking for panels: desktop only, each panel slides over the one before it. */

@media (min-width: 1024px) and (prefers-reduced-motion: no-preference) {
  /* The height cap keeps the caption in view: a sticky panel taller than the viewport would hide its own bottom. */
  .dgm-sc--panels.dgm-sc--sticky .dgm-sc__panel {
    position: sticky;
    top: 6rem;
    grid-template-rows: minmax(0, 1fr);
    height: min(calc(100svh - 7.5rem), 45rem);
  }

  .dgm-sc--panels.dgm-sc--sticky .dgm-sc__panel .dgm-sc__media {
    height: 100%;
    aspect-ratio: auto;
  }

  .dgm-sc--panels.dgm-sc--sticky .dgm-sc__panels {
    gap: 3rem;
  }
}
