/* ==========================================================================
   Brand story sections — Mission & Vision + Meet Our Founder
   (partials/mission-vision.php, partials/founder.php)
   Loaded on index.php and about.php. Uses the shared tokens, reveal
   system (data-reveal / .image-reveal) and the [data-inview] hook from
   assets/motion.js.
   ========================================================================== */

/* ---------- placeholder chip (founder fields not yet supplied) ---------- */
.ph-chip {
  display: inline-flex;
  align-items: center;
  vertical-align: middle;
  margin: 0 4px;
  padding: 3px 9px;
  border-radius: 999px;
  border: 1px dashed #C98A12;
  background: #FFF6E0;
  color: #8A5A00;
  font: 600 0.66rem/1.2 var(--font-body);
  letter-spacing: .08em;
  text-transform: uppercase;
  white-space: nowrap;
}

/* ==========================================================================
   MISSION & VISION
   ========================================================================== */
.mv {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(700px 360px at 12% 20%, rgba(15, 118, 110, 0.07), transparent 70%),
    radial-gradient(640px 360px at 90% 90%, rgba(244, 185, 66, 0.1), transparent 70%),
    var(--cream);
  padding: clamp(64px, 9vw, 120px) 0;
}
.mv__head { text-align: center; max-width: 720px; margin: 0 auto clamp(36px, 5vw, 56px); }
.mv__head .eyebrow { justify-content: center; }

.mv__grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.72fr) minmax(0, 1fr);
  gap: clamp(20px, 3vw, 40px);
  align-items: start;
}
.mv__grid > * { min-width: 0; }

/* connecting line, drawn when the section enters the viewport */
.mv__line {
  position: absolute;
  left: 0; right: 0;
  top: 46%;
  width: 100%;
  height: 120px;
  z-index: 0;
  pointer-events: none;
  overflow: visible;
}
.mv__line-track { fill: none; stroke: rgba(18, 53, 91, 0.12); stroke-width: 2; stroke-dasharray: 4 8; vector-effect: non-scaling-stroke; }
.mv__line-draw {
  fill: none; stroke: var(--accent); stroke-width: 2.5; stroke-linecap: round;
  vector-effect: non-scaling-stroke;
  stroke-dasharray: 100; stroke-dashoffset: 0;
  transition: stroke-dashoffset 1.8s cubic-bezier(.65, 0, .25, 1) .5s;
}
.motion .mv:not(.is-inview) .mv__line-draw { stroke-dashoffset: 100; }

.mv__panel {
  position: relative;
  z-index: 1;
  overflow: hidden;
  isolation: isolate;
  padding: clamp(26px, 3.4vw, 40px);
  border-radius: 24px;
  transition: transform .5s var(--ease-out), box-shadow .5s var(--ease-out);
}
.mv__panel--mission {
  background: #fff;
  border: 1px solid rgba(18, 53, 91, 0.08);
  box-shadow: 0 30px 60px -36px rgba(18, 53, 91, 0.4);
  margin-top: 0;
}
.mv__panel--vision {
  background: var(--navy);
  color: #fff;
  box-shadow: 0 34px 64px -30px rgba(8, 26, 46, 0.6);
  margin-top: clamp(0px, 6vw, 88px); /* offset for an asymmetric, overlapping rhythm */
}
@media (hover: hover) and (pointer: fine) {
  .mv__panel:hover { transform: translateY(-6px); }
}
/* oversized M / V behind the content */
.mv__letter {
  position: absolute;
  right: -6px; bottom: -34px;
  z-index: -1;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(9rem, 7rem + 6vw, 14rem);
  line-height: .8;
  letter-spacing: -0.06em;
  color: transparent;
  -webkit-text-stroke: 1.5px rgba(18, 53, 91, 0.08);
  pointer-events: none;
  user-select: none;
}
.mv__panel--vision .mv__letter { -webkit-text-stroke-color: rgba(248, 250, 252, 0.1); }
.mv__icon {
  display: grid; place-items: center;
  width: 54px; height: 54px;
  border-radius: 16px;
  margin-bottom: 20px;
  background: var(--accent-soft);
  color: var(--accent);
  transition: transform .5s cubic-bezier(.34, 1.56, .64, 1);
}
.mv__panel--vision .mv__icon { background: rgba(244, 185, 66, 0.16); color: var(--yellow); }
.mv__panel:hover .mv__icon { transform: rotate(-8deg) scale(1.06); }
.mv__title {
  font-size: clamp(1.8rem, 1.3rem + 1.8vw, 2.6rem);
  font-weight: 700;
  letter-spacing: -0.035em;
  margin: 0 0 12px;
}
.mv__panel--vision .mv__title { color: #fff; }
.mv__text { font-size: var(--fs-lead); line-height: 1.65; color: var(--ink-soft); margin: 0 0 20px; }
.mv__panel--vision .mv__text { color: var(--on-navy-soft); }
.mv__list { display: grid; gap: 10px; margin: 0; padding: 18px 0 0; list-style: none; border-top: 1px solid rgba(18, 53, 91, 0.1); }
.mv__panel--vision .mv__list { border-top-color: rgba(248, 250, 252, 0.14); }
.mv__list li { position: relative; padding-left: 26px; font-size: 0.95rem; font-weight: 500; color: var(--ink); }
.mv__panel--vision .mv__list li { color: rgba(248, 250, 252, 0.92); }
.mv__list li::before {
  content: ""; position: absolute; left: 0; top: .45em;
  width: 12px; height: 12px; border-radius: 50%;
  border: 3px solid var(--accent);
}
.mv__panel--vision .mv__list li::before { border-color: var(--yellow); }

.mv__photo {
  position: relative;
  z-index: 1;
  margin: clamp(0px, 3vw, 40px) 0 0;
  aspect-ratio: 4 / 5;
  border-radius: 160px 160px 24px 24px;   /* arch */
  overflow: hidden;
  box-shadow: 0 40px 70px -34px rgba(18, 53, 91, 0.5);
}
.mv__photo img { width: 100%; height: 100%; object-fit: cover; }
.mv__node {
  position: absolute; left: 50%; bottom: 18px;
  transform: translateX(-50%);
  display: flex; align-items: center; gap: 10px;
  padding: 8px 14px 8px 8px;
  border-radius: 999px;
  background: #fff;
  box-shadow: var(--shadow-md);
  font-size: 0.78rem; font-weight: 600; color: var(--ink-soft);
  white-space: nowrap;
}
.mv__node strong {
  display: grid; place-items: center;
  height: 32px; padding: 0 10px;
  border-radius: 999px;
  background: var(--navy); color: var(--yellow);
  font: 700 0.85rem var(--font-display);
}

@media (max-width: 991.98px) {
  .mv__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .mv__photo { grid-column: 1 / -1; grid-row: 1; aspect-ratio: 16 / 8; border-radius: 24px; margin: 0; }
  .mv__panel--vision { margin-top: 0; }
  .mv__line { display: none; }
}
@media (max-width: 767.98px) {
  .mv__grid { grid-template-columns: minmax(0, 1fr); }
  .mv__photo { aspect-ratio: 16 / 10; }
  .mv__letter { font-size: 8rem; bottom: -20px; }
}

/* ==========================================================================
   MEET OUR FOUNDER
   ========================================================================== */
.founder {
  position: relative;
  overflow: hidden;
  background: var(--bg);
  padding: clamp(64px, 9vw, 128px) 0;
}
.founder__bgword {
  position: absolute; right: -2%; top: 6%;
  font-family: var(--font-display); font-weight: 800;
  font-size: clamp(4rem, 12vw, 11rem); line-height: .85; letter-spacing: -0.05em;
  color: transparent; -webkit-text-stroke: 1.5px rgba(18, 53, 91, 0.06);
  white-space: nowrap;
  pointer-events: none; user-select: none;
}
.founder__grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(40px, 7vw, 104px);
  align-items: center;
}

/* --- portrait composition --- */
.founder__visual { position: relative; width: 100%; max-width: 460px; margin-inline: auto; padding: 0 0 36px 28px; }
.founder__shape {
  position: absolute; left: 0; top: 12%;
  width: 82%; aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, rgba(244, 185, 66, 0.35), rgba(15, 118, 110, 0.18) 60%, transparent 72%);
  filter: blur(2px);
  z-index: 0;
}
.founder__frame {
  position: absolute; left: 0; top: 28px; right: 28px; bottom: 8px;
  border: 1.5px solid rgba(15, 118, 110, 0.35);
  border-radius: 28px 140px 28px 28px;
  z-index: 0;
}
.founder__photo {
  position: relative; z-index: 1;
  margin: 0 0 0 auto;
  width: 92%;
  aspect-ratio: 4 / 5;
  border-radius: 28px 140px 28px 28px;
  overflow: hidden;
  box-shadow: 0 44px 80px -36px rgba(18, 53, 91, 0.55);
  background: var(--navy);
}
.founder__photo img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; }
.founder__photo--placeholder {
  display: grid; place-items: center; align-content: center; gap: 16px;
  background:
    radial-gradient(circle at 30% 20%, rgba(143, 212, 199, 0.25), transparent 55%),
    linear-gradient(160deg, #1b4a6f, var(--navy-dark));
  color: rgba(248, 250, 252, 0.55);
  text-align: center;
}
.founder__ph-mark { width: 38%; margin-top: 18%; }
.founder__photo--placeholder figcaption { display: grid; justify-items: center; gap: 10px; font-size: 0.9rem; font-weight: 600; color: rgba(248, 250, 252, 0.8); line-height: 1.35; }
.founder__badge {
  position: absolute; z-index: 2;
  left: 0; bottom: 64px;
  margin: 0;
  display: flex; align-items: center; flex-wrap: wrap; gap: 4px;
  max-width: 78%;
  padding: 12px 16px;
  border-radius: 14px;
  background: var(--yellow); color: var(--on-yellow);
  font: 700 0.92rem var(--font-display);
  box-shadow: 0 18px 34px -12px rgba(224, 166, 46, 0.65);
}
.founder__since {
  position: absolute; z-index: 2;
  right: -10px; top: 6%;
  margin: 0;
  display: flex; flex-direction: column;
  padding: 12px 16px;
  border-radius: 14px;
  background: #fff;
  box-shadow: var(--shadow-lg);
}
.founder__since strong { font: 700 1.5rem var(--font-display); color: var(--navy); letter-spacing: -0.02em; line-height: 1.1; }
.founder__since span { font-size: 0.74rem; color: var(--ink-soft); }
@media (prefers-reduced-motion: no-preference) {
  .founder__badge { animation: founderFloat 7s ease-in-out infinite; }
  .founder__since { animation: founderFloat 8s ease-in-out infinite reverse; }
  @keyframes founderFloat { 50% { translate: 0 -8px; } }
}

/* --- copy --- */
.founder__name {
  font-size: clamp(2.2rem, 1.5rem + 3vw, 3.8rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.02;
  margin: 0 0 8px;
}
.founder__cred { color: var(--accent); font-weight: 600; margin: 0 0 8px; }
.founder__quote {
  position: relative;
  margin: 26px 0 30px;
  padding: 8px 0 0 58px;
}
.founder__quote p {
  margin: 0;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1.35rem, 1.1rem + 1.1vw, 2rem);
  line-height: 1.35;
  color: var(--ink);
}
.founder__quote--placeholder p {
  font-family: var(--font-body);
  font-style: normal;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--ink-soft);
  padding: 16px 18px;
  border: 1px dashed rgba(18, 53, 91, 0.25);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.7);
}
.founder__quote--placeholder .ph-chip { margin-left: 0; }
.founder__quote-mark {
  position: absolute; left: 0; top: -18px;
  font: 400 6rem/1 var(--font-serif);
  color: var(--yellow);
  transform-origin: 40% 60%;
  transition: transform .8s cubic-bezier(.34, 1.56, .64, 1) .35s, opacity .5s var(--ease) .35s;
}
.motion .founder:not(.is-inview) .founder__quote-mark { transform: scale(.3) rotate(-20deg); opacity: 0; }

.founder__story { padding-top: 26px; border-top: 1px solid var(--line); }
.founder__story-text { color: var(--ink-soft); font-size: var(--fs-lead); line-height: 1.7; margin: 0 0 22px; max-width: 52ch; }
.founder__timeline {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 0 0 26px;
  padding: 0;
  list-style: none;
}
.founder__timeline::before, .founder__timeline::after {
  content: ""; position: absolute; left: 7px; right: 12%; top: 7px; height: 2px;
}
.founder__timeline::before { background: var(--line); }
.founder__timeline::after {
  background: linear-gradient(90deg, var(--accent), var(--yellow));
  transform-origin: left;
  transition: transform 1.6s cubic-bezier(.65, 0, .25, 1) .4s;
}
.motion .founder:not(.is-inview) .founder__timeline::after { transform: scaleX(0); }
.founder__timeline li { position: relative; padding-top: 26px; min-width: 0; }
.founder__timeline li::before {
  content: ""; position: absolute; left: 0; top: 0;
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--bg); border: 3px solid var(--accent);
  transition: transform .5s cubic-bezier(.34, 1.56, .64, 1), background-color .4s var(--ease);
}
.founder__timeline li:last-child::before { border-color: var(--yellow); background: var(--yellow); }
.motion .founder:not(.is-inview) .founder__timeline li::before { transform: scale(0); }
.founder.is-inview .founder__timeline li:nth-child(1)::before { transition-delay: .4s; }
.founder.is-inview .founder__timeline li:nth-child(2)::before { transition-delay: .8s; }
.founder.is-inview .founder__timeline li:nth-child(3)::before { transition-delay: 1.2s; }
.founder.is-inview .founder__timeline li:nth-child(4)::before { transition-delay: 1.6s; }
.founder__t-year { display: block; font: 700 1.1rem var(--font-display); color: var(--navy); letter-spacing: -0.02em; }
.founder__t-text { display: block; font-size: 0.82rem; color: var(--ink-soft); line-height: 1.4; }

@media (max-width: 991.98px) {
  .founder__grid { grid-template-columns: minmax(0, 1fr); }
  .founder__visual { max-width: 420px; }
}
@media (max-width: 575.98px) {
  .founder__visual { padding: 0 0 28px 14px; max-width: 300px; }
  .founder__photo { aspect-ratio: 5 / 6; }
  .founder__since { padding: 9px 12px; }
  .founder__since strong { font-size: 1.2rem; }
  /* badges sit on the frame edges so they never cover the face */
  .founder__visual { padding-top: 22px; }
  .founder__since { right: 0; top: 0; }
  .founder__badge { bottom: 6px; max-width: none; font-size: 0.84rem; flex-wrap: nowrap; }
  .founder__quote { padding-left: 40px; }
  .founder__quote-mark { font-size: 4.4rem; top: -10px; }
  .founder__timeline { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 20px; }
  .founder__timeline::before, .founder__timeline::after { display: none; }
}
