/* Segments contrast panel (src/components/solutions/SegmentsContrast.astro):
   a few grey segments beside many multicolour variants. */

.sc-compare {
  display: grid;
  gap: 16px;
  margin-top: var(--l-section-gap, 48px);
}
@media (min-width: 1024px) {
  .sc-compare { grid-template-columns: 1fr 2fr; gap: 24px; }
}

.sc-card {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 24px;
  border-radius: 20px;
  background: var(--kit-white, #fff);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--kit-ivory-medium) 70%, transparent), 0 10px 30px rgba(13, 40, 40, .05);
}
@media (min-width: 1024px) { .sc-card { padding: 32px; } }
.sc-card--today { background: var(--kit-ivory-tint, #f8f7f7); box-shadow: 0 0 0 1px rgba(32, 31, 29, .08); }

.sc-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.sc-label {
  font-family: var(--font-mono);
  font-size: var(--type-label-s);
  font-weight: 500;
  letter-spacing: var(--type-label-tracking);
  text-transform: uppercase;
  color: var(--kit-text-subtle);
}
.sc-label--on { color: var(--kit-teal-medium); }
.sc-count { font-size: var(--type-small); color: var(--kit-text-medium); }
.sc-count b {
  font-size: var(--type-h3);
  line-height: 1;
  font-weight: var(--type-heading-weight);
  color: var(--kit-text-strong);
  margin-right: 4px;
}
.sc-card--today .sc-count b { color: var(--kit-text-subtle); }

/* Mini email: hero block, two text lines, a button. */
.sc-mail {
  display: flex;
  flex-direction: column;
  gap: 7%;
  aspect-ratio: 3 / 4;
  padding: 10%;
  border-radius: 8px;
  background: var(--kit-white, #fff);
  box-shadow: 0 0 0 1px rgba(32, 31, 29, .08), 0 2px 6px rgba(13, 40, 40, .05);
}
.sc-mail i { display: block; border-radius: 3px; background: rgba(32, 31, 29, .12); }
.sc-mail .sc-hero { flex: 0 0 42%; border-radius: 4px; }
.sc-mail .sc-ln { height: 6%; }
.sc-mail .sc-ln--short { width: 65%; }
.sc-mail .sc-btn { height: 12%; width: 50%; margin-top: auto; border-radius: 999px; }

/* Today: three large, identical grey emails. */
.sc-today {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  flex: 1;
  align-content: center;
}
.sc-today li { display: flex; flex-direction: column; gap: 10px; }
.sc-mail--grey .sc-hero { background: rgba(32, 31, 29, .18); }
.sc-mail--grey .sc-btn { background: rgba(32, 31, 29, .28); }
.sc-name { font-size: var(--type-caption); color: var(--kit-text-subtle); text-align: center; }

/* With Stensul: a dense grid of variants, each in its own colours and layout. */
.sc-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
}
@media (min-width: 600px) { .sc-grid { grid-template-columns: repeat(8, 1fr); gap: 10px; } }
@media (min-width: 1024px) { .sc-grid { grid-template-columns: repeat(12, 1fr); gap: 8px; flex: 1; align-content: center; } }
@media (max-width: 599px) { .sc-grid li:nth-child(n + 37) { display: none; } }
.sc-grid .sc-mail { border-radius: 5px; padding: 12%; gap: 8%; }
.sc-grid .sc-mail i { border-radius: 2px; }

/* Layout variety: split hero, centred button, tall hero. */
.sc-l1 .sc-hero { flex-basis: 34%; width: 60%; }
.sc-l1 .sc-btn { margin-left: auto; margin-right: auto; }
.sc-l2 .sc-hero { flex-basis: 50%; }
.sc-l2 .sc-ln--short { display: none; }
.sc-l2 .sc-btn { width: 100%; }

.sc-h-teal .sc-hero { background: var(--kit-teal-shade); }
.sc-h-tealhi .sc-hero { background: var(--kit-teal-highlight); }
.sc-h-citron .sc-hero { background: var(--kit-citron-highlight); }
.sc-h-magenta .sc-hero { background: var(--color-magenta-medium); }
.sc-h-magentahi .sc-hero { background: var(--color-magenta-highlight, #f2a6d4); }
.sc-h-blue .sc-hero { background: var(--color-blue-blue-medium, #3b6fd8); }
.sc-h-tealmid .sc-hero { background: var(--kit-teal-medium); }

.sc-b-teal .sc-btn { background: var(--kit-teal-shade); }
.sc-b-tealhi .sc-btn { background: var(--kit-teal-medium); }
.sc-b-citron .sc-btn { background: var(--kit-citron-highlight); }
.sc-b-magenta .sc-btn { background: var(--color-magenta-medium); }
.sc-b-magentahi .sc-btn { background: var(--color-magenta-highlight, #f2a6d4); }
.sc-b-blue .sc-btn { background: var(--color-blue-blue-medium, #3b6fd8); }
.sc-b-tealmid .sc-btn { background: var(--kit-teal-highlight); }

.sc-foot { margin: 0; font-size: var(--type-small); color: var(--kit-text-subtle); }
.sc-chips { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; }
.sc-chip {
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--kit-citron-tint);
  font-family: var(--font-mono);
  font-size: var(--type-label-s);
  font-weight: 500;
  letter-spacing: var(--type-label-tracking);
  text-transform: uppercase;
  color: var(--kit-teal-dark);
}
.sc-x { color: var(--kit-text-subtle); }
/* Each "×" travels with the chip after it (no layout box in the default look). */
.sc-chipgrp { display: contents; }
@media (max-width: 599px) { .sc-x { display: none; } }

/* Build-in: the variants pop in one after another once in view. */
.sc-section.is-ready .sc-grid li { opacity: 0; transform: scale(.85); }
.sc-section.is-in .sc-grid li {
  opacity: 1;
  transform: none;
  transition: opacity .35s ease, transform .35s ease;
  transition-delay: calc(var(--i) * 28ms + 300ms);
}

/* ---------- look="email": the Platform features redesign's email part ----------
   Drawn in the Figma part's own units: the email is 137 wide and 158 tall,
   and --u is one unit at the email's rendered width. */
.sc--email .sc-em {
  --u: calc(100cqi / 137);
  container-type: inline-size;
  position: relative;
  display: flex;
  flex-direction: column;
  aspect-ratio: 137 / 148;
  border-radius: 2px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 2px 8px rgba(13, 40, 40, .08);
}
.sc--email .sc-em > *, .sc--email .sc-em-c > * { --u: calc(100cqi / 137); }
.sc--email .sc-em i { display: block; flex: none; }
.sc--email .sc-em-h {
  flex: none;
  height: calc(var(--u) * 12.5);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--kit-teal-dark, #0D2828);
}
.sc--email .sc-em-h img { width: calc(var(--u) * 28.9); height: auto; display: block; }
.sc--email .sc-em-c {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: calc(var(--u) * 5.95) calc(var(--u) * 8.93) calc(var(--u) * 8.7);
}
.sc--email .sc-em-c > * { flex: none; }
/* Today's generic email keeps its "November News" title as text. */
.sc--email .sc-em-title {
  height: calc(var(--u) * 8);
  margin-bottom: calc(var(--u) * 6);
  font-size: calc(var(--u) * 6.6);
  line-height: calc(var(--u) * 8);
  font-weight: 500;
  text-align: center;
  white-space: nowrap;
  color: #201F1D;
}
/* Photo: --h is its height in units. Bleed runs edge to edge. */
.sc--email .sc-em-img { display: block; height: calc(var(--u) * var(--h, 40)); overflow: hidden; }
.sc--email .sc-em-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sc--email .sc-em-img--focus { position: relative; container-type: size; }
/* Zoomed on a point (--fx, --fy) and centred on it, clamped so the photo
   always covers the frame. The photo is 640 x 427. */
.sc--email .sc-em-img--focus img {
  position: absolute;
  max-width: none;
  width: calc(100cqw * var(--z));
  height: calc(100cqw * var(--z) * .667);
  left: clamp(calc(100cqw - 100cqw * var(--z)), calc(50cqw - var(--fx) * 100cqw * var(--z)), 0px);
  top: clamp(calc(100cqh - 100cqw * var(--z) * .667), calc(50cqh - var(--fy) * 100cqw * var(--z) * .667), 0px);
}
.sc--email .sc-em-img--bleed { margin: calc(var(--u) * -5.95) calc(var(--u) * -8.93) 0; }
/* Headline: darker, taller grey bars; copy: the Figma part's lines. */
.sc--email .sc-em-hl, .sc--email .sc-em-sh, .sc--email .sc-em-ln { display: block; background: #6B665E; }
.sc--email .sc-em-hl { height: calc(var(--u) * 5.2); opacity: .6; border-radius: calc(var(--u) * 2.6); margin-bottom: calc(var(--u) * 2.6); }
.sc--email .sc-em-hl--c { margin-left: auto; margin-right: auto; }
.sc--email .sc-em-hl + .sc-em-img, .sc--email .sc-em-hl--c + .sc-em-img { margin-top: calc(var(--u) * 4.4); }
.sc--email .sc-em-img + .sc-em-hl, .sc--email .sc-em-side + .sc-em-ln, .sc--email .sc-em-img + .sc-em-ln { margin-top: calc(var(--u) * 7); }
.sc--email .sc-em-sh { height: calc(var(--u) * 4.76); opacity: .35; border-radius: calc(var(--u) * 2.4); margin-top: calc(var(--u) * 7.2); }
.sc--email .sc-em-hl + .sc-em-sh { margin-top: calc(var(--u) * 1.2); }
.sc--email .sc-em-ln { height: calc(var(--u) * 2.98); opacity: .35; border-radius: calc(var(--u) * 1.5); margin-top: calc(var(--u) * 2.38); }
.sc--email .sc-em-sh + .sc-em-ln { margin-top: calc(var(--u) * 3.6); }
.sc--email .sc-em-img + .sc-em-sh { margin-top: calc(var(--u) * 7.2); }
/* Side by side: photo and headline in a row (--r puts the photo right), the
   headline centred on the photo. */
.sc--email .sc-em-side { display: flex; gap: calc(var(--u) * 6); align-items: center; }
.sc--email .sc-em-side--r { flex-direction: row-reverse; }
.sc--email .sc-em-side .sc-em-img { flex: 0 0 48%; }
.sc--email .sc-em-side-t { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.sc--email .sc-em-side-t .sc-em-hl:last-child { margin-bottom: 0; }
.sc--email .sc-em-side-t .sc-em-hl { margin-bottom: calc(var(--u) * 2.4); }
.sc--email .sc-em-side-t .sc-em-hl + .sc-em-ln { margin-top: calc(var(--u) * 3); }
/* Button: teal, or Magenta in some versions; left or centred. */
.sc--email .sc-em-cta { display: block; height: calc(var(--u) * 10); margin-top: auto; border-radius: calc(var(--u) * 5); background: var(--kit-teal-medium, #0A7891); }
.sc--email .sc-em-cta--c { align-self: center; }
.sc--email .sc-em-cta--m { background: var(--color-magenta-medium, #a0307a); }
/* Today: the Self-Improving Email page's grey email (css/sie-explainer-compare.css,
   .sx-stack.sx-grey), drawn in its own units: 210 wide; --s is one unit. */
.sc--email .sc-sie {
  container-type: inline-size;
  display: flex;
  flex-direction: column;
  background: #fdfdfc;
  box-shadow: 0 2px 8px rgba(13, 40, 40, .06);
  border-radius: 6px;
}
.sc--email .sc-sie > * { --s: calc(100cqi / 210); }
.sc--email .sc-sie i { display: block; background: var(--color-neutrals-ivory-shade, #A8A39F); }
.sc--email .sc-sie-r { display: flex; align-items: center; padding: calc(var(--s) * 6) calc(var(--s) * 14); }
.sc--email .sc-sie-hd { padding-top: calc(var(--s) * 8); }
.sc--email .sc-sie-hd i { height: calc(var(--s) * 8); width: 34%; border-radius: calc(var(--s) * 2); }
.sc--email .sc-sie-hero { width: 100%; height: calc(var(--s) * 64); border-radius: calc(var(--s) * 3); }
.sc--email .sc-sie-prod { display: grid; grid-template-columns: repeat(3, 1fr); gap: calc(var(--s) * 7); }
.sc--email .sc-sie-prod i { height: calc(var(--s) * 32); border-radius: calc(var(--s) * 3); }
.sc--email .sc-sie-prod--two { grid-template-columns: repeat(2, 1fr); }
.sc--email .sc-sie-split { display: grid; grid-template-columns: 1fr 1fr; gap: calc(var(--s) * 10); align-items: center; }
.sc--email .sc-sie-split > i { height: calc(var(--s) * 64); border-radius: calc(var(--s) * 3); }
.sc--email .sc-sie-split span { display: flex; flex-direction: column; gap: calc(var(--s) * 4); }
.sc--email .sc-sie-split span i { height: calc(var(--s) * 5); border-radius: calc(var(--s) * 3); }
.sc--email .sc-sie-split span i + i { width: 80%; }
.sc--email .sc-sie-banner { width: 100%; height: calc(var(--s) * 24); border-radius: calc(var(--s) * 2); }
.sc--email .sc-sie-story { display: grid; grid-template-columns: calc(var(--s) * 30) 1fr; gap: calc(var(--s) * 10); }
.sc--email .sc-sie-story > i { height: calc(var(--s) * 30); border-radius: calc(var(--s) * 3); }
.sc--email .sc-sie-story span { display: flex; flex-direction: column; gap: calc(var(--s) * 4); }
.sc--email .sc-sie-story span i { height: calc(var(--s) * 5); border-radius: calc(var(--s) * 3); }
.sc--email .sc-sie-cta { width: calc(var(--s) * 46); height: calc(var(--s) * 10); border-radius: calc(var(--s) * 5); }
.sc--email .sc-sie-cta--full { width: 100%; }
.sc--email .sc-sie-ft { flex-direction: column; align-items: flex-start; gap: calc(var(--s) * 4); padding-bottom: calc(var(--s) * 8); }
.sc--email .sc-sie-ft i { height: calc(var(--s) * 4); width: 60%; border-radius: calc(var(--s) * 2); background: var(--color-neutrals-ivory-medium, #E4E1DF); }
.sc--email .sc-sie-ft i + i { width: 40%; }

/* With Stensul: the last tile says there are more versions. Below desktop the
   grid shows three rows (18 tiles on phones, 24 on tablets), and the "…" moves up
   to the last place shown. */
.sc--email .sc-more {
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  aspect-ratio: 137 / 148;
  border-radius: 2px;
  border: 1px dashed var(--color-neutrals-ivory-shade, #A8A39F);
  color: var(--kit-text-subtle);
}
/* Three dots drawn, not typed, so they sit at the box's exact centre. */
.sc--email .sc-more span { display: block; width: 22px; height: 6px; font-size: 0; background: radial-gradient(circle, currentColor 2.2px, transparent 2.7px) 0 0 / 8px 6px repeat-x; }
@media (max-width: 599px) {
  .sc--email .sc-grid li:nth-child(n + 18) { display: none; }
}
@media (min-width: 600px) and (max-width: 1023px) {
  .sc--email .sc-grid li:nth-child(n + 24) { display: none; }
}
@media (max-width: 1023px) {
  .sc--email .sc-grid li.sc-more { display: flex; }
}
.sc--email .sc-em-f {
  flex: none;
  position: relative;
  height: calc(var(--u) * 28.8);
  background: var(--kit-teal-dark, #0D2828);
}
.sc--email .sc-em-f img { position: absolute; left: calc(var(--u) * 8.93); top: calc(var(--u) * 12.63); width: calc(var(--u) * 24.75); height: auto; display: block; }
.sc--email .sc-em-f i { position: absolute; left: calc(var(--u) * 45.6); height: calc(var(--u) * 1.79); border-radius: 1px; background: #F8F7F7; opacity: .35; }
.sc--email .sc-em-f i:nth-of-type(1) { top: calc(var(--u) * 11.74); width: calc(var(--u) * 82); }
.sc--email .sc-em-f i:nth-of-type(2) { top: calc(var(--u) * 15.31); width: calc(var(--u) * 59.5); }

/* Email look: the count ("3 segments", "Every audience") at one size, the
   number semibold; each box's last line (the footnote, the chips) a step
   larger in strong ink, left-aligned; the "×" between chips at every width. */
.sc--email .sc-count, .sc--email .sc-count b { font-size: calc(var(--type-small, 14px) + 2px); line-height: 1.3; }
.sc--email .sc-count { font-weight: 400; }
.sc--email .sc-count b { margin-right: 0; font-weight: var(--type-subhead-weight, 600); }
.sc--email .sc-foot { font-size: calc(var(--type-small, 14px) + 2px); color: var(--kit-text-strong, #201F1D); }
.sc--email .sc-chip { padding: 6px 14px; font-size: calc(var(--type-label-s, 12px) + 2px); color: var(--kit-text-strong, #201F1D); }
.sc--email .sc-x { display: inline; font-size: calc(var(--type-small, 14px) + 2px); }
.sc--email .sc-chipgrp { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
/* Today a third, With Stensul two thirds, whatever their content's minimum width. */
@media (min-width: 1024px) { .sc--email .sc-compare { grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); } }

/* Headline over the photo (three versions): a dark overlay on the image, the
   headline bars in white on it, at the bottom left. */
.sc--email .sc-em-img--ov { position: relative; }
.sc--email .sc-em-img--ov::after { content: ''; position: absolute; inset: 0; background: rgba(13, 40, 40, .45); }
.sc--email .sc-em-ov {
  position: absolute;
  left: calc(var(--u) * 7);
  right: calc(var(--u) * 7);
  bottom: calc(var(--u) * 7);
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: calc(var(--u) * 2.6);
}
.sc--email .sc-em-hlw { display: block; height: calc(var(--u) * 5.2); border-radius: calc(var(--u) * 2.6); background: #fff; }
.sc--email .sc-em-img--ov + .sc-em-ln { margin-top: calc(var(--u) * 7); }
