/* About us page. Loaded by about/index.html only. Goal cards and the download band come from
   sections.css. */

/* Message from the Founder and Chairperson: a white card with a round portrait (olive ring)
   beside the message, a large faint quotation mark behind the text and a signature line. */
.founder-wrap {
  padding-block-end: 0;
}

.founder {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: grid;
  gap: var(--space-5);
  justify-items: center;
  padding: var(--space-6) var(--space-5);
  border: 1px solid var(--c-rule);
  border-radius: var(--radius-l);
  background: var(--c-surface);
  box-shadow: var(--shadow-card);
}

/* Olive band along the top edge */
.founder::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  block-size: 6px;
  background: linear-gradient(90deg, var(--c-emerald), var(--c-brass));
}

.founder__photo {
  inline-size: min(100%, 13.75rem);
  aspect-ratio: 1;
}

.founder__photo img {
  inline-size: 100%;
  block-size: 100%;
  object-fit: cover;
  object-position: 50% 30%;
  border: 6px solid var(--c-surface);
  border-radius: 50%;
  outline: 2px solid var(--c-brass);
  outline-offset: 4px;
  box-shadow: var(--shadow-photo);
}

.founder__text {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  max-inline-size: 44rem;
}

/* Large olive quotation mark behind the heading */
.founder__text::before {
  content: "\201C";
  position: absolute;
  inset-block-start: -0.35em;
  inset-inline-end: 0;
  z-index: -1;
  color: var(--c-brass);
  font-family: var(--font-head);
  font-size: 8rem;
  line-height: 1;
  opacity: 0.18;
}

.founder__text .label-pill + h2 {
  margin-block-start: calc(var(--space-1) * -1);
}

.founder__message {
  display: grid;
  gap: var(--space-3);
  margin: 0;
  padding-inline-start: var(--space-4);
  border-inline-start: 3px solid var(--c-brass);
}

.founder__message p {
  color: var(--c-ink-soft);
}

.founder__lead {
  color: var(--c-ink);
  font-family: var(--font-head);
  font-size: 1.1875rem;
  font-weight: 600;
  line-height: 1.45;
}

.founder__message .founder__close {
  color: var(--c-emerald);
  font-weight: 700;
}

.founder__sign {
  display: grid;
  gap: 2px;
  margin-block-start: var(--space-1);
}

.founder__sign strong {
  font-family: var(--font-head);
  font-size: 1.125rem;
}

.founder__sign span {
  color: var(--c-brass-text);
  font-size: var(--fs-small);
  font-weight: 700;
}

@media (min-width: 768px) {
  .founder {
    padding: var(--space-7);
  }
}

@media (min-width: 1024px) {
  .founder {
    grid-template-columns: 16.25rem minmax(0, 1fr);
    gap: var(--space-8);
    align-items: center;
    justify-items: start;
  }

  .founder__photo {
    inline-size: 100%;
  }
}

/* Quote band: green panel with the lattice */
/* The quote band follows the founder's card at the page's usual gap */
.quote-band-wrap {
  padding-block: var(--space-6) 0;
}

@media (min-width: 768px) {
  .quote-band-wrap {
    padding-block-start: var(--space-7);
  }
}

.quote-band {
  --focus: var(--c-brass);
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: calc(var(--space-6) + 2rem) var(--space-5) var(--space-6);
  border-radius: var(--radius-l);
  background: var(--c-night);
  color: var(--c-on-night);
  text-align: center;
}

.quote-band::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--c-on-night);
  opacity: 0.07;
  -webkit-mask: url("/assets/images/pattern-star-cross.svg") center / 96px 96px repeat;
  mask: url("/assets/images/pattern-star-cross.svg") center / 96px 96px repeat;
}

/* Large olive quotation mark */
.quote-band::after {
  content: "\201C";
  position: absolute;
  inset-block-start: var(--space-2);
  inset-inline-start: 50%;
  z-index: -1;
  color: var(--c-brass);
  font-family: var(--font-head);
  font-size: 6rem;
  line-height: 1;
  opacity: 0.45;
  translate: -50% 0;
}

.quote-band blockquote p {
  max-inline-size: 30ch;
  margin-inline: auto;
  font-family: var(--font-head);
  font-size: clamp(1.375rem, 1.15rem + 1.1vw, 2rem);
  font-weight: 700;
  line-height: 1.3;
  text-wrap: balance;
}

.quote-band figcaption {
  max-inline-size: 52ch;
  margin: var(--space-3) auto 0;
  color: var(--c-on-night-soft);
}

@media (min-width: 768px) {
  .quote-band {
    padding: calc(var(--space-6) + 2.5rem) var(--space-7) var(--space-6);
  }
}

/* Timeline: three steps, joined by a line */
.timeline {
  position: relative;
  display: grid;
  gap: var(--space-5);
  max-inline-size: none;
  padding: 0;
  list-style: none;
}

.timeline__step {
  position: relative;
  padding: var(--space-4);
  padding-inline-start: calc(var(--space-4) + 3.25rem);
  border: 1px solid var(--c-rule);
  border-radius: calc(var(--radius-l) - 12px);
  background: var(--c-surface);
  box-shadow: var(--shadow-card);
}

.timeline__marker {
  position: absolute;
  inset-block-start: var(--space-4);
  inset-inline-start: var(--space-4);
  display: grid;
  place-items: center;
  inline-size: 2.5rem;
  block-size: 2.5rem;
  border-radius: 50%;
  background: var(--c-emerald);
}

.timeline__marker .icon {
  fill: none;
  stroke: var(--c-brass);
  stroke-width: 1.4;
}

.timeline__when {
  color: var(--c-brass-text);
  font-family: var(--font-head);
  font-weight: 700;
}

.timeline__step h3 {
  margin-block: 2px var(--space-1);
  font-size: 1.125rem;
}

.timeline__step p:last-child {
  color: var(--c-ink-soft);
  font-size: var(--fs-small);
}

@media (min-width: 900px) {
  .timeline {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  /* The line runs through the markers, behind the cards */
  .timeline::before {
    content: "";
    position: absolute;
    inset-block-start: calc(var(--space-4) + 1.25rem);
    inset-inline: var(--space-4);
    border-block-start: 2px dashed var(--c-brass);
    opacity: 0.6;
  }

  .timeline__step {
    padding: calc(var(--space-4) + 3.25rem) var(--space-4) var(--space-4);
  }
}

/* Compact goal cards (this page): tighter padding, no medallion. The icon sits beside the title
   only when the card is wide enough; in a narrow card (phones, the two-column tablet layout) it
   would squeeze the purpose text into a thin column, so it stays above the title there. */
.goal-cards--compact .goal-cards__emblem {
  display: none;
}

.goal-cards--compact .goal-card {
  container-type: inline-size;
}

.goal-cards--compact .goal-card__head {
  row-gap: var(--space-2);
  padding: var(--space-5);
}

.goal-cards--compact .goal-card__head .icon-badge {
  margin: 0 0 var(--space-2);
}

@container (min-width: 26rem) {
  .goal-cards--compact .goal-card__head {
    grid-template-columns: auto 1fr;
    align-items: center;
    column-gap: var(--space-4);
  }

  .goal-cards--compact .goal-card__head .icon-badge {
    grid-row: span 2;
    margin: 0;
  }
}

.goal-cards--compact .goal-card__head h3 {
  font-size: 1.5rem;
}

.goal-cards--compact .goal-card__head p {
  font-size: var(--fs-small);
}

.goal-cards--compact .goal-card__star {
  inline-size: 8rem;
  block-size: 8rem;
}

.goal-cards--compact .goal-card__body {
  gap: var(--space-4);
  padding: var(--space-5);
}

.goal-cards--compact .checklist li + li {
  margin-block-start: var(--space-2);
  padding-block-start: var(--space-2);
}

/* ---------- Our team ----------
   Patron in chief first: a dark green feature card with the lattice texture, a large portrait
   in a double olive ring and a faint eight-pointed star outline behind the text. Office bearers
   and members: profile cards with a cream head (faint lattice), the round portrait overlapping
   it, a short role tag, the name, the title in olive and the other lines under a dashed rule. Group headings sit centred between two olive lines. */
.team__group {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  max-inline-size: 40rem;
  margin: var(--space-8) auto var(--space-6);
  color: var(--c-emerald);
  font-size: clamp(1.25rem, 1.1rem + 0.6vw, 1.5rem);
  text-align: center;
}

.team__group::before,
.team__group::after {
  content: "";
  flex: 1;
  min-inline-size: 2rem;
  block-size: 2px;
  border-radius: var(--radius-pill);
}

.team__group::before {
  background: linear-gradient(to left, var(--c-brass), transparent);
}

.team__group::after {
  background: linear-gradient(to right, var(--c-brass), transparent);
}

/* Patron in chief */
.patron {
  display: grid;
  justify-items: center;
  gap: var(--space-5);
  overflow: hidden;
  margin-block-start: var(--space-7);
  padding: var(--space-6) var(--space-5);
  border-radius: var(--radius-l);
  box-shadow: var(--shadow-photo);
  text-align: center;
}

/* Large faint star outline at the right edge */
.patron::after {
  content: "";
  position: absolute;
  inset-block-start: 50%;
  inset-inline-end: -5rem;
  z-index: -1;
  inline-size: 22rem;
  aspect-ratio: 1;
  background: var(--c-brass);
  opacity: 0.22;
  translate: 0 -50%;
  -webkit-mask: url("/assets/images/khatam-outline.svg") center / contain no-repeat;
  mask: url("/assets/images/khatam-outline.svg") center / contain no-repeat;
  pointer-events: none;
}

.patron__photo {
  display: block;
  flex: none;
  inline-size: 11rem;
}

.patron__photo img {
  display: block;
  inline-size: 100%;
  block-size: auto;
  aspect-ratio: 1;
  border: 4px solid var(--c-brass);
  border-radius: 50%;
  outline: 1px solid var(--c-brass);
  outline-offset: 6px;
}

.patron__text {
  display: grid;
  gap: var(--space-2);
  justify-items: center;
}

.patron__kicker {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--c-on-night-soft);
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.patron__kicker .icon {
  inline-size: 1.125rem;
  block-size: 1.125rem;
  color: var(--c-brass);
}

.patron h4 {
  color: var(--c-on-night);
  font-size: clamp(1.625rem, 1.3rem + 1.2vw, 2.25rem);
  line-height: 1.15;
  letter-spacing: -0.01em;
}

.patron__quals {
  color: var(--c-on-night-soft);
  font-size: 0.9375rem;
  letter-spacing: 0.02em;
}

.patron__roles {
  display: grid;
  gap: var(--space-2);
  max-inline-size: none;
  margin: var(--space-3) 0 0;
  padding: var(--space-4) 0 0;
  border-block-start: 1px solid color-mix(in srgb, var(--c-on-night) 20%, transparent);
  list-style: none;
  color: var(--c-on-night);
  font-size: var(--fs-small);
  line-height: 1.45;
  text-align: start;
}

.patron__roles li {
  display: flex;
  gap: var(--space-3);
}

.patron__roles li::before,
.person__more li::before {
  content: "";
  flex: none;
  inline-size: 0.4rem;
  block-size: 0.4rem;
  margin-block-start: 0.55em;
  background: var(--c-brass);
  rotate: 45deg;
}

@media (min-width: 768px) {
  .patron {
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: var(--space-7);
    padding: var(--space-7) var(--space-8) var(--space-7) var(--space-7);
    text-align: start;
  }

  .patron__text {
    justify-items: start;
  }

  .patron__photo {
    inline-size: 13rem;
  }
}

/* Office bearers and members */
/* Cards fill the content width, so their outer edges line up with the founder's card, the
   quote band and the patron's card: one column on phones, two on tablets (an odd last card is
   centred), then three office bearers and four members in a row. */
.people {
  display: grid;
  gap: var(--space-5);
  max-inline-size: none;
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 640px) {
  .people {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .people > :last-child:nth-child(odd) {
    grid-column: 1 / -1;
    justify-self: center;
    inline-size: calc(50% - var(--space-5) / 2);
  }
}

@media (min-width: 1024px) {
  .people--office {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .people--members {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .people > :last-child:nth-child(odd) {
    grid-column: auto;
    inline-size: auto;
  }
}

.person {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--c-rule);
  border-radius: calc(var(--radius-l) - 12px);
  background: var(--c-surface);
  box-shadow: var(--shadow-card);
  text-align: center;
}

@media (prefers-reduced-motion: no-preference) {
  .person {
    transition: translate 250ms ease, box-shadow 250ms ease;
  }

  .person:hover {
    translate: 0 -4px;
    box-shadow: var(--shadow-photo);
  }
}

/* Cream head with a faint lattice; the portrait hangs over its lower edge */
.person__head {
  position: relative;
  isolation: isolate;
  display: grid;
  justify-items: center;
  block-size: 6rem;
  padding-block-start: var(--space-5);
  background: var(--c-cream);
}

.person__head::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--c-brass);
  opacity: 0.25;
  -webkit-mask: url("/assets/images/pattern-star-cross.svg") center / 64px 64px repeat;
  mask: url("/assets/images/pattern-star-cross.svg") center / 64px 64px repeat;
}

.person__photo {
  display: block;
  inline-size: 8.5rem;
}

.person__photo img {
  display: block;
  inline-size: 100%;
  block-size: auto;
  aspect-ratio: 1;
  border: 5px solid var(--c-surface);
  border-radius: 50%;
  outline: 2px solid var(--c-brass);
  box-shadow: var(--shadow-photo);
}

.person__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  padding: calc(4.25rem + var(--space-3)) var(--space-4) var(--space-4);
}

.person__tag {
  padding: 0.125rem var(--space-3);
  border-radius: var(--radius-pill);
  background: var(--c-emerald);
  color: var(--c-on-emerald);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.person h4 {
  font-size: 1.125rem;
  line-height: 1.3;
}

.person__quals {
  color: var(--c-ink-soft);
  font-weight: 400;
}

.person__title {
  color: var(--c-brass-text);
  font-size: var(--fs-small);
  font-weight: 700;
  line-height: 1.4;
}

.person__more {
  display: grid;
  gap: var(--space-2);
  align-self: stretch;
  max-inline-size: none;
  margin: var(--space-2) 0 0;
  padding: var(--space-3) var(--space-1) 0;
  border-block-start: 1px dashed var(--c-rule);
  list-style: none;
  color: var(--c-ink-soft);
  font-size: 0.9375rem;
  line-height: 1.45;
  text-align: start;
}

.person__more li {
  display: flex;
  gap: var(--space-3);
}

/* ---------- Collaborators ----------
   Its own soft green panel. National, then international, each under a heading with an icon
   badge and a count. Each collaborator is a small white card: round initials in one of three
   alternating tints, the name, and the lines of detail (the first a little darker). Three
   across on desktop, two on tablets, one on phones. */
.collab + .collab {
  margin-block-start: var(--space-7);
}

.collab__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2) var(--space-3);
  margin-block-end: var(--space-4);
  padding-block-end: var(--space-3);
  border-block-end: 2px solid var(--c-brass);
}

.collab__icon {
  display: grid;
  place-items: center;
  inline-size: 2.5rem;
  block-size: 2.5rem;
  border-radius: 50%;
  background: var(--c-emerald);
  color: var(--c-on-emerald);
}

.collab__icon .icon {
  inline-size: 1.25rem;
  block-size: 1.25rem;
}

.collab__head h3 {
  color: var(--c-emerald);
  font-size: clamp(1.25rem, 1.1rem + 0.6vw, 1.5rem);
}

.collab__count {
  margin-inline-start: auto;
  padding: 0.125rem var(--space-3);
  border: 1px solid var(--c-rule);
  border-radius: var(--radius-pill);
  background: var(--c-surface);
  color: var(--c-ink-soft);
  font-size: 0.875rem;
  font-weight: 700;
}

.collab__grid {
  display: grid;
  gap: var(--space-3);
  max-inline-size: none;
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 640px) {
  .collab__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--space-4);
  }
}

@media (min-width: 1024px) {
  .collab__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.collab__item {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  overflow: hidden;
  padding: var(--space-4);
  border: 1px solid var(--c-rule);
  border-radius: var(--radius-m);
  background: var(--c-surface);
  box-shadow: var(--shadow-raise);
  transition: border-color 200ms ease;
}

/* Olive line along the top on hover */
.collab__item::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  block-size: 3px;
  background: var(--c-brass);
  opacity: 0;
  transition: opacity 200ms ease;
}

.collab__item:hover {
  border-color: var(--c-brass);
}

.collab__item:hover::before {
  opacity: 1;
}

.collab__avatar {
  display: grid;
  place-items: center;
  flex: none;
  inline-size: 2.75rem;
  block-size: 2.75rem;
  border: 1px solid var(--c-rule);
  border-radius: 50%;
  background: var(--c-dawn);
  color: var(--c-emerald);
  font-family: var(--font-head);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.collab__item:nth-child(3n + 2) .collab__avatar {
  background: var(--c-olive-tint);
}

.collab__item:nth-child(3n) .collab__avatar {
  background: var(--c-cream);
}

.collab__info {
  display: grid;
  gap: var(--space-2);
  min-inline-size: 0;
}

.collab__name {
  color: var(--c-ink);
  font-family: var(--font-body);
  font-size: var(--fs-small);
  font-weight: 700;
  line-height: 1.35;
}

.collab__title,
.collab__quals {
  color: var(--c-ink-soft);
  font-weight: 400;
}

.collab__more {
  display: grid;
  gap: var(--space-1);
  max-inline-size: none;
  margin: 0;
  padding: var(--space-2) 0 0;
  border-block-start: 1px dashed var(--c-rule);
  list-style: none;
  color: var(--c-ink-soft);
  font-size: 0.9375rem;
  line-height: 1.45;
}

.collab__more li:first-child {
  color: var(--c-ink);
}

@media (prefers-reduced-motion: reduce) {
  .collab__item,
  .collab__item::before {
    transition: none;
  }
}
