/* ==========================================================================
   Numera - pages/about.css
   The About page (generator/templates/about.html): the partner cards, how accounts are run and the two cards of the
   what-Numera-does block. css/pages.css holds what the other pages share (page head, callout, band, nav) and
   base.html links this file after it. The what-Numera-does block is a shared callout section: the teal ground, the
   white text and the title come from pages.css, so only its two white cards are written here. Logical properties
   make the same rules work in Arabic; only the fonts and sizes are set again for it, because main.css gives the
   small labels a Latin font that Tajawal has to replace.
   ========================================================================== */

/* A link to #partners, #how-accounts-run or #partner-ahmed (the url of a Person in the JSON-LD) must not land under
   the sticky nav */
.partners[id],
.partner[id],
.run[id] { scroll-margin-top: 96px; }

.partners__title,
.run__title { text-wrap: balance; }

/* ---- The partners: one white card each, the photo and the name side by side, the bio below ---- */
.partners {
  padding: 64px 0 72px;
  background: var(--c-ground-deep);
  border-top: 1px solid var(--c-line);
}
.partners__title {
  margin-bottom: 32px;
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.015em;
  font-weight: 700;
}
.partners__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
.partner {
  padding: 28px 30px 32px;
  background: var(--c-white);
  border: 1px solid var(--c-line);
  border-radius: 16px;
}
.partner__head {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 22px;
}
.partner__photo {
  flex: 0 0 96px;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--c-line);
}
/* min-width 0: a flex item does not shrink below its longest word unless it is told it may */
.partner__id { min-width: 0; }
.partner__name {
  font-size: 24px;
  line-height: 1.2;
  letter-spacing: -0.01em;
  font-weight: 700;
  color: var(--c-ink);
}
.partner__role {
  margin-top: 6px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--c-primary);
}
.partner__creds {
  margin-top: 6px;
  font-size: 15px;
  line-height: 1.45;
  color: var(--c-muted);
}
.partner__bio {
  font-size: 16.5px;
  line-height: 1.65;
  color: rgba(10,21,23,0.84);
}

/* ---- How accounts are run: four statements, each with a small icon ---- */
.run {
  padding: 64px 0 72px;
  background: var(--c-ground);
}
.run__title {
  margin-bottom: 32px;
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.015em;
  font-weight: 700;
}
.run__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.run__item {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  padding: 24px 26px;
  background: var(--c-white);
  border: 1px solid var(--c-line);
  border-radius: 16px;
}
.run__icon {
  display: flex;
  flex: 0 0 44px;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(20,82,76,0.09);
  color: var(--c-primary);
}
.run__svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.run__text {
  font-size: 17px;
  line-height: 1.55;
  color: rgba(10,21,23,0.86);
}
.run__more { margin-top: 28px; }
.run__link {
  font-size: 16px;
  font-weight: 600;
  color: var(--c-primary);
  text-underline-offset: 4px;
}

/* ---- What Numera does and what licensed professionals do: two white cards on the teal callout ---- */
.scope__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin-top: 28px;
}
.scope__card {
  padding: 28px 30px 30px;
  background: var(--c-white);
  border-top: 6px solid transparent;
  border-radius: 16px;
  color: var(--c-ink);
}
.scope__card--numera { border-top-color: var(--c-accent); }
.scope__card--licensed { border-top-color: var(--c-secondary); }
.scope__card-title {
  margin-bottom: 18px;
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: -0.01em;
  font-weight: 700;
  color: var(--c-primary);
}
.scope__list { margin: 0; }
.scope__name {
  margin: 20px 0 6px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--c-primary);
}
.scope__name:first-child { margin-top: 0; }
.scope__lead {
  margin-bottom: 14px;
  font-size: 18px;
  font-weight: 500;
  line-height: 1.5;
  color: var(--c-primary);
}
.scope__text {
  margin: 0;
  font-size: 16.5px;
  line-height: 1.6;
  color: rgba(10,21,23,0.86);
}

/* Phone: one column, tighter cards. main.css switches its layout at 760px, so this page does too. */
@media (max-width: 760px) {
  .partners,
  .run { padding: 48px 0 56px; }
  .partners__title,
  .run__title { margin-bottom: 24px; }
  .partners__grid,
  .run__grid,
  .scope__grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .partner {
    padding: 22px 20px 24px;
    border-radius: 14px;
  }
  .partner__head {
    gap: 16px;
    margin-bottom: 18px;
  }
  .partner__photo {
    flex-basis: 80px;
    width: 80px;
    height: 80px;
  }
  .partner__name { font-size: 22px; }
  .run__item {
    gap: 14px;
    padding: 18px;
    border-radius: 14px;
  }
  .scope__grid { margin-top: 20px; }
  .scope__card {
    padding: 22px 20px 24px;
    border-radius: 14px;
  }
}

/* ---- Arabic: Tajawal on the labels that are set in a Latin font above, larger sizes for Arabic letters ---- */
[dir="rtl"] .partners__title,
[dir="rtl"] .run__title,
[dir="rtl"] .partner__name,
[dir="rtl"] .scope__card-title { line-height: 1.25; }
[dir="rtl"] .partner__role,
[dir="rtl"] .scope__name {
  font-family: var(--font-arabic);
  font-size: 15px;
  text-transform: none;
}
[dir="rtl"] .partner__creds { font-size: 16px; }
[dir="rtl"] .partner__bio,
[dir="rtl"] .scope__text { font-size: 18px; }
[dir="rtl"] .run__text { font-size: 18px; }
[dir="rtl"] .scope__lead { font-size: 19px; }
[dir="rtl"] .run__link { font-size: 17px; }
