/* Banner: a plain Fashion White band with the title and one line */
.v2 #main > section.team-banner { padding-block: clamp(3rem, 6vw, 4.5rem); border-bottom: 1px solid var(--line); text-align: center; }
.team-banner h1 { margin: 0 auto; }
.team-banner-lede { max-width: 38rem; margin: 1rem auto 0; font-size: 1.1rem; line-height: 1.55; color: var(--text-muted); }
.team-banner .btn { margin-top: 1.75rem; }

/* Our team page. Builds on styles.css and projects.css. */

.team-intro { padding: clamp(4rem, 9vw, 7rem) 0 clamp(2.5rem, 5vw, 4rem); }
.team-intro h1 { font-size: var(--title-size); letter-spacing: -0.045em; line-height: .95; }
.team-why { display: grid; grid-template-columns: minmax(0, 46rem); gap: 2rem 4rem; margin-top: clamp(2rem, 4vw, 3rem); align-items: end; }
.team-why p { font-size: clamp(1.15rem, 1.8vw, 1.4rem); line-height: 1.45; letter-spacing: -0.02em; }
.ring-key { display: flex; align-items: center; gap: .75rem; font-size: .9rem; color: var(--on-dark-muted); }
.ring-key svg { width: 42px; height: 42px; flex: none; }
.ring-key > span { width: 46px; height: 46px; flex: none; position: relative; }

.team-grid-wrap { padding-bottom: clamp(4rem, 8vw, 6rem); }
/* Team cards: three across, full-colour photos */
.ac-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2.5rem 1.5rem; align-items: start; }

/* Photo: full colour in a rounded frame */
.ac-photo { position: relative; display: block; width: 100%; padding: 0; border: 0; overflow: hidden; aspect-ratio: 4 / 5; border-radius: var(--radius); background: #e4e1da; cursor: pointer; }
.ac-photo:focus-visible { outline: 2px solid var(--forest); outline-offset: 3px; }
.ac-photo img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 0;
  transform-origin: 50% 100%; transition: scale 1250ms var(--ease-out); }
/* The photo grows from its bottom edge, so the top of the head never crops */
.ac-card:is(:hover, :focus-within) .ac-photo img { scale: 1.04; }

/* Name, role and the + toggle */
.ac-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; margin-top: .9rem; }
.ac-card .ac-name { margin: 0; font-size: 1.2rem; font-weight: 500; line-height: 1.2; letter-spacing: -0.02em; color: var(--ink); }
.ac-role { margin: .15rem 0 0; font-size: .85rem; color: var(--text-muted); }
.ac-toggle { position: relative; flex: none; width: 36px; height: 36px; margin-top: -.2rem; border: 1px solid var(--line); border-radius: 50%; background: none; cursor: pointer;
  transition: background 200ms var(--ease-out), border-color 200ms var(--ease-out), rotate 300ms var(--acorn-ease-slide); }
.ac-toggle span, .ac-toggle span::after { position: absolute; left: 50%; top: 50%; width: 12px; height: 1.5px; translate: -50% -50%; background: var(--ink); }
.ac-toggle span::after { content: ""; rotate: 90deg; }
.ac-toggle:hover, .ac-toggle:focus-visible { border-color: var(--ink); }
@media (max-width: 900px) { .ac-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .ac-grid { grid-template-columns: 1fr; } }
@media (prefers-reduced-motion: reduce) {
  .ac-photo img, .ac-toggle { transition: none; }
}

/* Ringed portraits: used by the layout review pages (team-*-options.html), not the team page */

/* Person */
.person {
  display: grid; justify-items: center; gap: .9rem; text-align: center; width: 100%;
  padding: .5rem .5rem 1rem; background: none; border: 0; border-radius: var(--radius);
  color: var(--on-dark); font: inherit; cursor: pointer;
  transition: transform 200ms var(--ease-out), scale 140ms var(--ease-out);
}
.person:focus-visible { outline: 2px solid var(--mint); outline-offset: 4px; }
@media (hover: hover) and (pointer: fine) { .person:hover { transform: translateY(-4px); } }
.person-name { font-weight: 500; font-size: 1.08rem; letter-spacing: -0.02em; }
.person-role { font-size: .88rem; color: var(--on-dark-faint); margin-top: .15rem; }
.person-years { font-size: .78rem; color: var(--mint); margin-top: .5rem; }

/* Portrait with experience rings */
.portrait-wrap { position: relative; width: 100%; max-width: 270px; aspect-ratio: 1; display: grid; place-items: center; }
/* Brand tree rings, cut to a circle; they open outward from the portrait to the circle's edge as the person comes into view */
.rings-art { position: absolute; inset: 0; width: 100%; height: 100%; display: block;
  clip-path: circle(38% at 50% 50%); transition: clip-path 3800ms cubic-bezier(.2, .6, .35, 1); }
.is-grown .rings-art { clip-path: circle(50% at 50% 50%); }


/* Full-color portrait. Hover scans a duotone (Green Ink shadows, Mint highlights) down behind a mint line, which then fades back to color. */
.portrait { position: relative; width: var(--size, 62%); aspect-ratio: 1; border-radius: 50%; overflow: hidden; isolation: isolate; }
.portrait img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.duo { position: absolute; inset: 0; z-index: 1; background: var(--mint); clip-path: inset(0 0 100% 0); }
.duo img { filter: grayscale(1) contrast(1.15) brightness(1.05); mix-blend-mode: multiply; }
.duo::after { content: ""; position: absolute; inset: 0; background: var(--ink); mix-blend-mode: lighten; }
.scan { position: absolute; z-index: 2; left: -5%; right: -5%; top: 0; height: 2px; background: var(--mint); box-shadow: 0 0 12px 2px rgba(204, 246, 100, .7); opacity: 0; transform: translateY(-4px); }
.person:focus-visible .duo { animation: duo-scan 1100ms var(--acorn-ease-slide) forwards; }
.person:focus-visible .scan { animation: scan 700ms var(--acorn-ease-slide) forwards; }
@media (hover: hover) and (pointer: fine) {
  .person:hover .duo { animation: duo-scan 1100ms var(--acorn-ease-slide) forwards; }
  .person:hover .scan { animation: scan 700ms var(--acorn-ease-slide) forwards; }
}
@keyframes scan { 0% { opacity: 1; transform: translateY(0); } 90% { opacity: 1; } 100% { opacity: 0; transform: translateY(calc(var(--px, 130px))); } }
@keyframes duo-scan { 0% { clip-path: inset(0 0 100% 0); opacity: 1; } 64% { clip-path: inset(0 0 0 0); opacity: 1; } 100% { clip-path: inset(0 0 0 0); opacity: 0; } }

/* Profile pop-up: Fashion White, a floating close button, and the photo on a Mint block set slightly behind it */
.profile {
  width: min(920px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); padding: 0;
  border: 0; border-radius: var(--radius); background: var(--paper); color: var(--ink); overflow: hidden;
}
/* Opens in 300ms, closes faster (160ms) */
.profile {
  opacity: 0; transform: translateY(12px) scale(.985);
  transition: opacity 160ms var(--ease-out), transform 160ms var(--ease-out), overlay 160ms allow-discrete, display 160ms allow-discrete;
}
.profile[open] { display: flex; flex-direction: column; opacity: 1; transform: none; transition-duration: 300ms; }
@starting-style { .profile[open] { opacity: 0; transform: translateY(12px) scale(.985); } }
.profile::backdrop { background: rgba(14, 37, 27, .55); backdrop-filter: blur(4px); opacity: 0; transition: opacity 160ms ease, overlay 160ms allow-discrete, display 160ms allow-discrete; }
.profile[open]::backdrop { opacity: 1; transition-duration: 240ms; }
@starting-style { .profile[open]::backdrop { opacity: 0; } }
/* The bar holds only the close button, floating in the corner; the crumb stays for screen readers */
.profile-bar { position: absolute; top: .9rem; right: .9rem; z-index: 2; }
.profile-bar > span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.profile-close { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); background: var(--paper); color: var(--ink); font-size: 1.3rem; cursor: pointer; transition: background 150ms, border-color 150ms; }
.profile-close:hover { background: var(--mint); border-color: var(--mint); }
.profile-body { display: grid; grid-template-columns: 300px 1fr; gap: clamp(1.5rem, 4vw, 3rem); padding: clamp(2rem, 4.5vw, 3rem) clamp(1.5rem, 4vw, 2.75rem) clamp(1.5rem, 4vw, 2.75rem); overflow-y: auto; }
/* The photo stays in view while the details scroll beside it */
.profile-side { position: sticky; top: 0; align-self: start; display: grid; justify-items: center; align-content: start; gap: 1rem; padding: 0 14px 14px 0; text-align: center; }
.profile-ph { display: block; width: 100%; max-width: 280px; aspect-ratio: 4 / 5; overflow: hidden; border-radius: 14px; box-shadow: 14px 14px 0 var(--mint); }
.profile-ph img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 0; }
.profile-main h2 { font-size: var(--title-size); line-height: 1; color: var(--ink); }
.profile-main .person-role { font-size: 1.05rem; margin-top: .5rem; color: var(--text-muted); }
/* LinkedIn icon under the role */
.profile-li { display: inline-grid; place-items: center; width: 1.75rem; height: 1.75rem; margin-top: .9rem; color: var(--forest); transition: transform 200ms var(--ease-out); }
.profile-li svg { width: 100%; height: 100%; fill: currentColor; }
.profile-li:hover { transform: translateY(-2px); }
.profile-main p { color: var(--text-muted); line-height: 1.65; }
.profile-main p + p { margin-top: .9rem; }
/* The profile: a short bio, two numbers (tokens used and preferred IDE), the typical workflow and the special sauce */
.profile-list { display: grid; gap: 1.5rem; margin: 1.75rem 0 0; }
.profile-list dt { font-size: .75rem; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--forest); }
.profile-list dd { margin: .45rem 0 0; color: var(--text-muted); line-height: 1.6; }
.profile-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.profile-stats > div { padding: 1rem 1rem 1rem 0; }
.profile-stats > div + div { padding-left: 1.25rem; border-left: 1px solid var(--line); }
.profile-list dd.profile-stat { font-size: 1.6rem; font-weight: 500; letter-spacing: -0.03em; line-height: 1.1; color: var(--ink); }
/* Details a person hasn't sent yet */
.profile-soon { font-style: italic; color: rgba(14, 37, 27, .4); }
.profile-list dd.profile-stat .profile-soon { font-size: 1.1rem; font-weight: 400; letter-spacing: 0; }
html.modal-open { overflow: hidden; }

@media (max-width: 760px) {
  .team-why, .profile-body { grid-template-columns: 1fr; }
  .profile-side { position: static; }
  .profile-stats { grid-template-columns: 1fr; }
  .profile-stats > div + div { padding-left: 0; border-left: 0; border-top: 1px solid var(--line); }
  .profile-ph { max-width: 240px; }
}
@media (prefers-reduced-motion: reduce) {
  .rings-art { transition: none; }
  .person:hover .scan, .person:hover .duo, .person:focus-visible .scan, .person:focus-visible .duo { animation: none; }
  .profile, .profile::backdrop { transition: none; transform: none; }
  .profile-li { transition: none; }
}

/* Our Founding Team: one Green Ink panel per founder, the photo filling one side and swapping sides for the second person */
.ft-panels { display: grid; gap: 1.5rem; }
.ft-panel { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); min-height: clamp(30rem, 42vw, 36rem); overflow: hidden; border-radius: var(--radius); background: var(--ink); color: var(--paper); }
.ft-panel.is-flip { grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); }
.ft-panel.is-flip .ft-photo { order: 2; }
.ft-photo { position: relative; }
.ft-photo img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 10%; }
.ft-info { align-self: center; padding: clamp(1.75rem, 3.5vw, 3rem); }
.ft-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; }
.v2 .ft-name { margin: 0; font-size: var(--title-size); line-height: 1; letter-spacing: -0.04em; color: var(--paper); }
.ft-role { margin: .5rem 0 0; font-size: 1.05rem; color: rgba(247, 243, 234, .78); }
.ft-li { flex: none; display: grid; place-items: center; width: 1.75rem; height: 1.75rem; margin-top: .25rem; color: var(--mint); transition: transform 200ms var(--ease-out); }
.ft-li svg { width: 100%; height: 100%; fill: currentColor; }
@media (hover: hover) and (pointer: fine) { .ft-li:hover { transform: translateY(-2px); } }
.ft-li:focus-visible { outline: 2px solid var(--mint); outline-offset: 3px; }
.ft-list { display: grid; gap: 1.5rem; margin: 1.75rem 0 0; }
.ft-field dt { font-size: .75rem; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--mint); }
.ft-field dd { margin: .45rem 0 0; line-height: 1.6; color: rgba(247, 243, 234, .78); }
.ft-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-block: 1px solid rgba(247, 243, 234, .16); }
.ft-stats .ft-field { padding: .75rem 1rem .75rem 0; }
.ft-stats .ft-field + .ft-field { padding-left: 1.25rem; border-left: 1px solid rgba(247, 243, 234, .16); }
.ft-stats dd { font-size: 1.25rem; font-weight: 500; letter-spacing: -0.03em; line-height: 1.1; color: var(--paper); }
.ft-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2rem; }
/* Details a founder hasn't sent yet */
.ft-soon { font-style: italic; color: rgba(247, 243, 234, .6); }
.ft-stats dd .ft-soon { font-size: 1rem; font-weight: 400; letter-spacing: 0; }

/* Tablet and phone: photo first for both people */
@media (max-width: 860px) {
  .ft-panel, .ft-panel.is-flip { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .ft-panel.is-flip .ft-photo { order: 0; }
  .ft-photo { aspect-ratio: 1; }
}
@media (max-width: 560px) {
  .ft-stats, .ft-pair { grid-template-columns: minmax(0, 1fr); }
  .ft-pair { gap: 1.5rem; }
  .ft-stats .ft-field + .ft-field { padding-left: 0; border-left: 0; border-top: 1px solid rgba(247, 243, 234, .16); }
}
@media (prefers-reduced-motion: reduce) { .ft-li { transition: none; } }
