/* Shared article closing blocks. All rules stay inside the two rendered roots. */
.article-end-trust,
.article-end-social {
  box-sizing: border-box;
  min-width: 0;
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding: clamp(2rem, 5vw, 4rem) clamp(1rem, 4vw, 3.4rem);
  color: var(--ink);
  font-family: Roboto, system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: clamp(1rem, 1.6vw, 1.09375rem);
  font-weight: 300 !important;
  line-height: 1.6;
  overflow-wrap: anywhere;
}

:is(.article-end-trust, .article-end-social) *,
:is(.article-end-trust, .article-end-social) *::before,
:is(.article-end-trust, .article-end-social) *::after {
  box-sizing: border-box;
  min-width: 0;
}

/* Component display rules must never override the server's no-JS fallback. */
:is(.article-end-trust, .article-end-social) [hidden] {
  display: none !important;
}

:is(.article-end-trust, .article-end-social) :is(h2, h3) {
  margin: 0 0 1rem;
  color: var(--green);
  font-family: Newsreader, Georgia, serif;
  font-size: 28px;
  font-weight: 400 !important;
  line-height: 1.12;
  letter-spacing: -.025em;
  text-wrap: pretty;
}

:is(.article-end-trust, .article-end-social) :is(a, button, summary, .eyebrow) {
  font-weight: 400 !important;
}

:is(.article-end-trust, .article-end-social) p {
  max-width: 70ch;
  margin: 0 0 1rem;
}

:is(.article-end-trust, .article-end-social) a {
  color: var(--purple);
  white-space: normal;
  text-decoration: underline;
  text-underline-offset: .2em;
  cursor: pointer;
}

:is(.article-end-trust, .article-end-social) :is(a, button, summary, [data-carousel-track]):focus-visible {
  outline: 3px solid var(--purple);
  outline-offset: 3px;
}

.article-end-trust .article-end-bio {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.25rem;
  align-items: start;
  padding: clamp(1rem, 3vw, 2rem);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--white);
}

.article-end-trust .article-end-bio > img {
  width: 120px;
  max-width: 100%;
  height: 140px;
  border-radius: var(--r-md);
  object-fit: cover;
  object-position: 62% 22%;
}

.article-end-trust .article-end-reviews {
  margin-top: clamp(2rem, 5vw, 3.5rem);
}

.article-end-trust .article-end-section-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: .5rem 1.5rem;
  align-items: end;
  margin-bottom: 1.25rem;
}

:is(.article-end-trust, .article-end-social) .article-end-carousel {
  --article-end-gap: 1rem;
  min-width: 0;
  max-width: 100%;
}

:is(.article-end-trust, .article-end-social) .article-end-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 100%;
  align-items: start;
  gap: var(--article-end-gap);
  min-width: 0;
  max-width: 100%;
  padding-block: .25rem .75rem;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scroll-behavior: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--green) var(--cream);
}

:is(.article-end-trust, .article-end-social) .article-end-track > [data-carousel-card] {
  width: 100%;
  height: auto;
  min-height: 0;
  max-height: none;
  aspect-ratio: auto;
  align-self: start;
  scroll-snap-align: start;
  scroll-margin-block: .25rem;
}

.article-end-trust .article-end-review,
.article-end-social .article-end-media-card {
  padding: clamp(.75rem, 2vw, 1.5rem);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--white);
  overflow: visible;
}

.article-end-trust .article-end-review blockquote {
  display: block;
  height: auto;
  max-height: none;
  margin: 0 0 1rem;
  overflow: visible;
  color: var(--green);
  font-family: Newsreader, Georgia, serif;
  font-size: 1.09375rem;
  font-weight: 400 !important;
  line-height: 1.5;
  white-space: pre-wrap;
  -webkit-line-clamp: unset;
  -webkit-box-orient: initial;
}

.article-end-trust .article-end-review > p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 1rem;
}

:is(.article-end-trust, .article-end-social) .article-end-controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: .75rem;
  margin-top: .75rem;
}

:is(.article-end-trust, .article-end-social) .article-end-controls button,
.article-end-social [data-social-load] {
  min-height: 44px;
  max-width: 100%;
  padding: .6rem 1rem;
  border: 1px solid var(--green);
  border-radius: var(--pill);
  background: var(--white);
  color: var(--green);
  font: inherit;
  font-weight: 400 !important;
  line-height: 1.4;
  white-space: normal;
  cursor: pointer;
}

:is(.article-end-trust, .article-end-social) .article-end-controls button {
  flex: 0 0 44px;
  padding-inline: .5rem;
}

:is(.article-end-trust, .article-end-social) [data-carousel-status] {
  min-width: 5ch;
  color: var(--muted);
  font-size: 1rem;
  text-align: center;
}

:is(.article-end-trust, .article-end-social) .article-end-controls button:disabled {
  opacity: .45;
  cursor: not-allowed;
}

:is(.article-end-trust, .article-end-social) .article-end-controls button:hover:not(:disabled),
.article-end-social [data-social-load]:hover:not([aria-disabled="true"]) {
  background: var(--green);
  color: var(--white);
}

.article-end-social [data-social-load][aria-disabled="true"] {
  border-color: var(--line);
  background: var(--cream);
  cursor: default;
}

:is(.article-end-trust, .article-end-social) .article-end-caption,
.article-end-social .article-end-language {
  margin: 1rem 0 0;
  color: var(--muted);
  font-size: 1rem;
  font-weight: 300 !important;
  line-height: 1.55;
}

.article-end-social > h2 {
  max-width: 24ch;
}

.article-end-social > details[data-social-panel] {
  margin-top: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--white);
}

.article-end-social > .social-instagram {
  background: var(--cream);
}

.article-end-social > .social-facebook {
  background: var(--pacific);
}

.article-end-social details[data-social-panel] > summary {
  padding: 1rem;
  border-radius: var(--r-md);
  color: var(--green);
  font: inherit;
  font-weight: 400 !important;
  cursor: pointer;
}

.article-end-social details[data-social-panel] > summary::marker {
  color: var(--purple);
}

.article-end-social details[data-social-panel] > summary > span {
  display: block;
  margin-top: .3rem;
  color: var(--muted);
  font-weight: 300 !important;
}

.article-end-social details[data-social-panel][open] > summary {
  border-bottom: 1px solid var(--line);
  border-end-start-radius: 0;
  border-end-end-radius: 0;
}

.article-end-social details[data-social-panel] > :is(.article-end-carousel, .article-end-media-card, .article-end-caption) {
  margin: .75rem .6rem 1rem;
}

.article-end-social .article-end-media-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1rem;
}

.article-end-social .article-end-media-card > :is(h3, p, a) {
  margin: 0;
}

.article-end-social .article-end-media-mark {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--pacific);
  color: var(--green);
  font-size: 1.25rem;
  line-height: 1;
}

.article-end-social [data-social-embed] {
  width: 100%;
  max-width: 100%;
}

.article-end-social [data-social-embed]:empty {
  display: none;
}

.article-end-social [data-social-embed] iframe {
  display: block;
  width: 100%;
  max-width: 100%;
  border: 0;
  border-radius: var(--r-sm);
  background: var(--cream);
}

.article-end-social [data-social-embed][data-provider="youtube"] iframe {
  aspect-ratio: 16 / 9;
  height: auto;
  min-height: 200px;
}

.article-end-social [data-social-embed][data-provider="instagram"] :is(.instagram-media, iframe) {
  min-width: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
}

.article-end-social [data-social-embed][data-provider="instagram"] .instagram-media {
  margin: 0 !important;
}

.article-end-social [data-social-embed][data-provider="facebook"] iframe {
  width: 267px;
  max-width: 100%;
  height: 476px;
}

.article-end-social .article-end-media-card blockquote { margin: 0; font-size: 1.05rem; font-weight: 300; line-height: 1.6; }

@media (min-width: 600px) {
  .article-end-trust .article-end-bio {
    grid-template-columns: 120px minmax(0, 1fr);
  }
}

@media (min-width: 900px) {
  :is(.article-end-trust, .article-end-social) :is(h2, h3) {
    font-size: 38px;
  }

  :is(.article-end-trust, .article-end-social) .article-end-track {
    grid-auto-columns: calc((100% - var(--article-end-gap)) / 2);
  }

  .article-end-trust .article-end-section-head {
    grid-template-columns: minmax(0, 1fr) auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  :is(.article-end-trust, .article-end-social) *,
  :is(.article-end-trust, .article-end-social) *::before,
  :is(.article-end-trust, .article-end-social) *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
