/* Founder: profile header, story, dossier, and the signed letter that closes the page */

.founder-hero {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--gutter);
  align-items: center;
  padding: calc(var(--header-h) + clamp(48px, 6vw, 96px)) var(--edge) clamp(64px, 8vw, 120px);
}

.founder-hero__media {
  position: relative;
  grid-column: 1 / span 4;
  max-width: 420px;
}

.founder-hero__dots {
  position: absolute;
  left: -24%;
  bottom: -20%;
  width: 90%;
  aspect-ratio: 1;
  background-image: radial-gradient(var(--turquoise) 1.6px, transparent 2px);
  background-size: 12px 12px;
  -webkit-mask: radial-gradient(circle at 70% 30%, #000 30%, transparent 72%);
  mask: radial-gradient(circle at 70% 30%, #000 30%, transparent 72%);
  opacity: 0.6;
}

.founder-hero__photo {
  position: relative;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 2rem;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  transition:
    transform 1.6s var(--ease-out),
    opacity 1.6s var(--ease-out);
}

.js:not(.is-ready) .founder-hero__photo {
  opacity: 0;
  transform: translateY(40px) scale(0.97);
}

.founder-hero__body {
  grid-column: 6 / span 7;
}

.founder-hero__body .back-pill {
  display: flex;
  width: fit-content;
}

.founder-hero__name {
  font-size: clamp(48px, 1rem + 4.6vw, 104px);
  font-weight: 600;
  line-height: 0.95;
  letter-spacing: -0.05em;
}

.founder-hero__role {
  margin-top: 18px;
  font-size: clamp(18px, 0.9rem + 0.5vw, 24px);
  font-weight: 500;
  color: var(--turquoise);
}

.founder-hero__quote {
  margin: clamp(28px, 3vw, 44px) 0 0;
  padding-left: 22px;
  border-left: 3px solid var(--yellow);
  font-size: clamp(24px, 1rem + 1.3vw, 38px);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.js .founder-hero__body > * {
  transition:
    transform 1.4s var(--ease-out),
    opacity 1.4s var(--ease-out),
    background-color 0.3s ease,
    color 0.3s ease;
  transition-delay: calc(var(--d, 0) * 110ms + 200ms);
}

.js:not(.is-ready) .founder-hero__body > * {
  opacity: 0;
  transform: translateY(18px);
}

/* Story: one lead that lights up as you read, two supporting columns */
.founder-story {
  padding: clamp(48px, 6vw, 96px) var(--edge);
}

.founder-story__lead {
  max-width: 34ch;
  font-size: clamp(26px, 1rem + 1.8vw, 48px);
  font-weight: 600;
  line-height: 1.18;
  letter-spacing: -0.025em;
}

.founder-story__cols {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--gutter);
  max-width: 1100px;
  margin-top: clamp(40px, 4.4vw, 64px);
}

.founder-story__cols p {
  font-size: 18px;
  line-height: 1.6;
  color: var(--on-dark-muted);
}

/* Dossier: label / value rows on hairlines */
.dossier {
  padding: clamp(80px, 9vw, 140px) var(--edge) clamp(96px, 11vw, 160px);
}

.dossier__title {
  margin-bottom: clamp(32px, 3.6vw, 52px);
  font-size: clamp(36px, 0.8rem + 3vw, 68px);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.04em;
}

.dossier__list {
  margin: 0;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
}

.dossier__list > div {
  display: grid;
  grid-template-columns: minmax(180px, 3fr) 9fr;
  gap: 12px var(--gutter);
  padding: 22px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
}

.dossier__list dt {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--turquoise);
}

.dossier__count {
  display: inline-grid;
  place-items: center;
  min-width: 26px;
  height: 26px;
  margin-left: 6px;
  border-radius: 999px;
  background: var(--yellow);
  color: var(--surface-deep);
  font-size: 12px;
  letter-spacing: 0;
  vertical-align: middle;
}

.dossier__list dd {
  margin: 0;
  font-size: clamp(17px, 0.9rem + 0.35vw, 21px);
  font-weight: 500;
  line-height: 1.45;
}

.dossier__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.dossier__tags li {
  padding: 6px 12px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  transition:
    border-color 0.3s ease,
    color 0.3s ease;
}

.dossier__tags li:hover {
  border-color: var(--yellow);
  color: var(--yellow);
}

/* Letter CTA: a signed note sealed in a Berecons envelope. The seal opens and closes it. */
@property --p {
  syntax: "<number>";
  inherits: true;
  initial-value: 0;
}

.letter {
  overflow: hidden;
  padding: clamp(80px, 9vw, 140px) var(--edge) 0;
  background:
    radial-gradient(circle at 50% 100%, rgba(56, 206, 187, 0.16), transparent 60%),
    var(--surface-deep);
}

.letter__stage {
  --p: 0;
  position: relative;
  overflow: hidden;
  max-width: 900px;
  margin: 0 auto;
  padding: 24px 40px 174px;
  transition: --p 1.3s var(--ease-out);
}

.letter__stage.is-open {
  --p: 1;
}

/* The wrap holds the visible height: a peek when sealed, the full note when open */
.letter__wrap {
  height: calc(var(--peek) + (var(--open-h, 640px) - var(--peek)) * var(--p));
  --peek: clamp(170px, 18vw, 220px);
}

.letter__card {
  position: relative;
  z-index: 1;
  padding: clamp(32px, 5vw, 64px);
  border-radius: 6px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0) 30%),
    #f4f2ec;
  box-shadow:
    0 30px 60px rgba(0, 0, 0, 0.45),
    0 2px 0 rgba(255, 255, 255, 0.7) inset;
  color: #1b1c1e;
  transform: rotate(calc(var(--p) * -1.2deg));
}

.letter__kicker {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #0f8f80;
}

.letter__title {
  margin: 12px 0 22px;
  font-size: clamp(34px, 1rem + 2.6vw, 60px);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.04em;
}

.letter__text {
  max-width: 58ch;
  font-size: clamp(16px, 0.9rem + 0.3vw, 19px);
  line-height: 1.6;
  color: #3b3d41;
}

.letter__text + .letter__text {
  margin-top: 14px;
}

.letter__text strong {
  color: #1b1c1e;
}

.letter__sign {
  margin-top: 18px;
  height: clamp(64px, 7vw, 92px);
}

/* The signature writes itself over the last stretch of the opening */
.letter__script {
  display: inline-block;
  font-family: "Mrs Saint Delafield", cursive;
  font-size: clamp(54px, 6vw, 84px);
  line-height: 1.2;
  color: #1b1c1e;
  clip-path: inset(0 calc((1 - clamp(0, (var(--p) - 0.6) / 0.4, 1)) * 100%) 0 0);
}

.letter__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 28px;
  margin-top: 20px;
}

.letter__btn .btn__label {
  background: #1b1c1e;
  color: var(--white);
}

.letter__btn:hover .btn__label {
  background: var(--turquoise);
  color: #1b1c1e;
}

.letter__btn .btn__dot {
  background: var(--yellow);
}

.letter__btn:hover .btn__dot {
  background: #1b1c1e;
  color: var(--white);
}

/* Contact icons: details stay hidden until hover or focus */
.letter__icons {
  display: flex;
  gap: 10px;
}

.letter__icon {
  position: relative;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(27, 28, 30, 0.35);
  border-radius: 50%;
  color: #1b1c1e;
  transition: all 0.3s ease;
}

.letter__icon:hover,
.letter__icon:focus-visible {
  transform: translateY(-3px);
  border-color: #1b1c1e;
  background: #1b1c1e;
  color: var(--yellow);
}

.letter__icon::after {
  content: attr(data-tip);
  position: absolute;
  bottom: calc(100% + 10px);
  left: 50%;
  padding: 6px 10px;
  border-radius: 8px;
  background: #1b1c1e;
  color: var(--white);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  translate: -50% 4px;
  transition:
    opacity 0.25s ease,
    translate 0.25s ease;
}

.letter__icon:hover::after,
.letter__icon:focus-visible::after {
  opacity: 1;
  translate: -50% 0;
}

/* Envelope front over the bottom of the stage */
.letter__pocket {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  display: grid;
  justify-items: center;
  align-content: start;
  height: 190px;
  padding-top: 26px;
  border-radius: 14px 14px 0 0;
  background:
    linear-gradient(160deg, transparent 49.6%, rgba(255, 255, 255, 0.06) 50%, transparent 50.4%) left / 50% 100% no-repeat,
    linear-gradient(20deg, transparent 49.6%, rgba(255, 255, 255, 0.06) 50%, transparent 50.4%) right / 50% 100% no-repeat,
    linear-gradient(180deg, #2c2e31, #232427);
  box-shadow: 0 -20px 40px rgba(0, 0, 0, 0.35);
}

/* The seal: the Berecons mark as the open / close button, ringed and pulsing until used */
.letter__seal {
  position: relative;
  width: 68px;
  height: 68px;
  border: 0;
  border-radius: 50%;
  background: url("/assets/site/mark-color.png") center / 26px auto no-repeat, var(--surface);
  box-shadow:
    0 0 0 2px var(--turquoise),
    0 10px 24px rgba(0, 0, 0, 0.45);
  cursor: pointer;
  transition:
    transform 0.35s var(--ease-out),
    box-shadow 0.35s ease;
}

.letter__seal::before,
.letter__seal::after {
  content: "";
  position: absolute;
  inset: -2px;
  border: 2px solid var(--turquoise);
  border-radius: 50%;
  animation: seal-pulse 2.2s cubic-bezier(0.2, 0.6, 0.3, 1) infinite;
}

.letter__seal::after {
  border-color: var(--yellow);
  animation-delay: 1.1s;
}

@keyframes seal-pulse {
  0% {
    opacity: 0.9;
    transform: scale(1);
  }
  100% {
    opacity: 0;
    transform: scale(1.7);
  }
}

.letter__seal:hover,
.letter__seal:focus-visible {
  transform: scale(1.08) rotate(-8deg);
  box-shadow:
    0 0 0 2px var(--yellow),
    0 12px 28px rgba(0, 0, 0, 0.5);
}

.letter__seal:focus-visible {
  outline: 2px solid var(--white);
  outline-offset: 6px;
}

/* Once open, the seal stops calling for attention */
.is-open .letter__seal::before,
.is-open .letter__seal::after {
  animation: none;
  opacity: 0;
}

.letter__hint {
  margin-top: 14px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--turquoise);
  transition: color 0.3s ease;
}

.is-open .letter__hint {
  color: var(--grey);
}

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

  .letter__seal::before,
  .letter__seal::after {
    animation: none;
  }
}

@media (max-width: 960px) {
  .founder-hero__media,
  .founder-hero__body {
    grid-column: 1 / -1;
  }

  .founder-hero__media {
    max-width: min(300px, 72vw);
    margin-bottom: 40px;
  }

  .founder-story__cols {
    grid-template-columns: 1fr;
  }

  .dossier__list > div {
    grid-template-columns: 1fr;
  }

  .letter__stage {
    padding: 24px 14px 150px;
  }

  .letter__pocket {
    height: 166px;
  }
}
