/* Partnerships: the client's own idea, organisations as ecological roles. One motif, the thread. */

/* ---------- Hero ---------- */
.pt-hero { position: relative; min-height: 72svh; display: grid; align-items: end; color: #fff; isolation: isolate; }
.pt-hero-media { position: absolute; inset: 0; z-index: -2; overflow: hidden; background: #14251c; }
.pt-hero-media img { width: 100%; height: 100%; object-fit: cover; }
.pt-hero-inner { padding: calc(var(--header-h) + 6vh) 0 clamp(36px, 6vh, 64px); display: grid; gap: 22px; }
.pt-hero h1 { font-size: var(--t-88); max-width: 20ch; text-shadow: 0 2px 30px rgba(6,18,12,.35); }
.pt-hero h1 em { color: var(--sprout); font-style: italic; }
.pt-hero .lede { color: rgba(255,255,255,.94); max-width: 34em; text-shadow: 0 1px 18px rgba(6,18,12,.5); }
.pt-hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 6px; }
@media (max-width: 640px) { .pt-hero h1 { font-size: clamp(34px, 10vw, 48px); } }


/* ---------- Ecological roles ---------- */
.pt-roles { padding: calc(var(--sect) * .9) 0; background: var(--mist); overflow: hidden; }
.pt-roles-head { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(20px, 4vw, 64px); align-items: end; }
.pt-roles h2 { font-size: var(--t-64); color: var(--forest); max-width: 20ch; }
.pt-roles h2 em { color: var(--leaf); font-style: italic; }
.pt-roles-lede { font-size: var(--t-22); line-height: 1.45; color: var(--stone); max-width: 30ch; padding-bottom: 8px; }
.pt-roles-lede b { display: block; margin-top: 8px; font: italic 500 var(--t-28) / 1.2 var(--display); color: var(--moss); }
@media (max-width: 900px) { .pt-roles-head { grid-template-columns: 1fr; align-items: start; } .pt-roles-lede { margin-top: 18px; } }

.pt-roles-row { position: relative; margin-top: clamp(44px, 6vw, 72px); }
.pt-roles-inner { position: relative; }
/* The thread is built in partnerships.js from the measured circle centres, so it runs through
   every one of them in reading order instead of behind the first row only. */
.pt-roles-thread { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; overflow: visible; pointer-events: none; }
.pt-roles-thread .pt-march { stroke: var(--leaf); animation: pt-march 3.4s linear infinite; }
/* one whole dash period (5 + 4.5) times three, or the pattern jumps each loop */
@keyframes pt-march { to { stroke-dashoffset: -28.5px; } }
.pt-roles-list { position: relative; z-index: 1; list-style: none; display: flex; gap: 20px; }
.pt-role { flex: 0 0 auto; width: 190px; text-align: center; scroll-snap-align: center; }
.pt-role-photo { display: block; width: 120px; height: 120px; margin: 0 auto 16px; border-radius: 50%; overflow: hidden; border: 3px solid var(--mist); box-shadow: 0 0 0 1.5px var(--line-strong); transition: box-shadow .7s var(--ease); }
.pt-role-photo img { width: 100%; height: 100%; object-fit: cover; }
/* The ring lights as the drawn tip of the thread passes the circle. */
.pt-role.is-lit .pt-role-photo { box-shadow: 0 0 0 5px var(--sprout), 0 0 0 6.5px rgba(78,154,91,.5); }
.pt-role h3 { font-family: var(--display); font-weight: 500; font-size: var(--t-22); color: var(--forest); line-height: 1.1; }
.pt-role p { margin-top: 8px; font-size: 13.5px; line-height: 1.4; color: var(--stone); }
.pt-role-link { display: block; color: inherit; text-decoration: none; border-radius: var(--r-12); padding: 4px 6px 10px; }
.pt-role-photo img { transition: transform .8s var(--ease); }
.pt-role-cta { display: inline-flex; align-items: center; gap: 6px; margin-top: 12px; font-size: 13px; font-weight: 500; color: var(--moss); opacity: 0; transform: translateY(4px); transition: opacity .35s var(--ease), transform .35s var(--ease); }
.pt-role-cta .arrow { width: 14px; height: 14px; }
.pt-role-link:hover .pt-role-photo, .pt-role-link:focus-visible .pt-role-photo { box-shadow: 0 0 0 5px var(--sprout), 0 0 0 6.5px rgba(78,154,91,.5); }
.pt-role-link:hover .pt-role-photo img { transform: scale(1.08); }
.pt-role-link:hover .pt-role-cta, .pt-role-link:focus-visible .pt-role-cta { opacity: 1; transform: none; }
.pt-role-link:focus-visible { outline: 2px solid var(--leaf); outline-offset: 2px; }
@media (hover: none) { .pt-role-cta { opacity: 1; transform: none; } }
.pt-roles-hint { display: none; margin-top: 16px; font-family: var(--display); font-style: italic; font-size: 15px; color: var(--moss); }

/* Phones and tablets: the roles stack, circle and words side by side, flipping sides each time,
   with the thread weaving down through the circles. Nothing is hidden off the edge. */
@media (max-width: 859px) {
  .pt-roles-list { flex-direction: column; gap: 76px; }
  .pt-role { width: auto; text-align: left; }
  .pt-role-link { display: grid; grid-template-columns: 112px minmax(0, 1fr); align-items: center; column-gap: 20px; padding: 0; }
  .pt-role-photo { grid-row: 1 / span 3; width: 112px; height: 112px; margin: 0; }
  .pt-role-photo + h3, .pt-role h3, .pt-role p, .pt-role-cta { grid-column: 2; }
  .pt-role h3 { align-self: end; font-size: 24px; }
  .pt-role p { margin-top: 6px; font-size: 15px; }
  .pt-role-cta { margin-top: 8px; justify-self: start; opacity: 1; transform: none; }
  .pt-role:nth-child(even) .pt-role-link { grid-template-columns: minmax(0, 1fr) 112px; text-align: right; }
  .pt-role:nth-child(even) .pt-role-photo { grid-column: 2; }
  .pt-role:nth-child(even) h3, .pt-role:nth-child(even) p, .pt-role:nth-child(even) .pt-role-cta { grid-column: 1; }
  .pt-role:nth-child(even) .pt-role-cta { justify-self: end; }
  .pt-roles-hint { display: none; }
}
@media (min-width: 860px) {
  /* the inline padding keeps a clear gutter either side of the circles: it is where the thread
     turns from one row into the next without crossing a caption */
  .pt-roles-list { flex-wrap: wrap; justify-content: center; row-gap: clamp(52px, 6vw, 80px); column-gap: 24px; padding-inline: 62px; }
  .pt-role { width: calc(25% - 18px); }
}

/* ---------- Pioneer Species Programme: the card is a membership card, over the photograph ---------- */
.pt-pioneer { padding: calc(var(--sect) * .9) 0 calc(var(--sect) * .8); }
/* The photograph runs the height of the section on the left, the words sit at its top right and
   the card is laid across its edge: one composition, not a two column grid. */
.pt-pioneer-stage { display: grid; grid-template-columns: minmax(0, 1.02fr) minmax(0, .98fr); grid-template-rows: auto auto auto; align-items: start; }
.pt-pioneer-photo { grid-column: 1; grid-row: 1 / span 2; align-self: stretch; margin: 0; min-height: 420px; overflow: hidden; }
.pt-pioneer-photo img { width: 100%; height: 100%; object-fit: cover; }
.pt-pioneer-copy { grid-column: 2; grid-row: 1; max-width: 46ch; padding: 0 0 clamp(30px, 4vw, 48px) clamp(28px, 3.4vw, 52px); }
.pt-pioneer-copy h2 { font-size: var(--t-48); color: var(--forest); }
.pt-pioneer-copy .lede { margin-top: 16px; }
.pt-pioneer-copy p:not(.lede) { margin-top: 14px; color: var(--stone); }
.pt-pioneer-copy .btn { margin-top: 26px; }
.pt-pioneer-cta { grid-column: 1; grid-row: 3; justify-self: start; margin-top: clamp(32px, 4vw, 44px); }

/* The ticket: the approved plate, stamped. */
.pt-ticket { background: #fff; border: 1.5px solid var(--forest); padding: 9px 9px 7px; box-shadow: 8px 8px 0 rgba(18, 56, 42, .12); transition: transform .6s var(--ease), box-shadow .6s var(--ease); }
.pt-ticket-pioneer { grid-column: 2; grid-row: 2; align-self: end; z-index: 2; margin-left: -60px; transform: rotate(-.8deg); }
.pt-ticket-pioneer:hover { transform: rotate(-.8deg) translateY(-3px); box-shadow: 11px 11px 0 rgba(18, 56, 42, .16); }
.pt-ticket-head { position: relative; display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 14px 14px 18px; border-bottom: 1.5px solid var(--forest); }
.pt-ticket-title { font-size: var(--t-36); line-height: 1.02; color: var(--forest); max-width: 8ch; }
.pt-ticket-title em { font-style: italic; color: var(--moss); }
.pt-stamp { flex: none; width: 96px; height: 96px; margin: -6px -4px -24px 0; color: var(--moss); animation: pt-stamp-spin 54s linear infinite; }
.pt-stamp-disc { fill: var(--canvas); }
.pt-stamp-ring { font: 500 8.6px var(--sans); letter-spacing: 1.7px; text-transform: uppercase; }
.pt-stamp-word { font: italic 500 13px var(--display); }
@keyframes pt-stamp-spin { from { transform: rotate(-9deg); } to { transform: rotate(351deg); } }

.pt-ledger { list-style: none; margin: 0; padding: 0 14px; }
.pt-ledger li { display: flex; align-items: baseline; justify-content: space-between; gap: 18px; padding: 15px 0 14px; border-bottom: 1px dotted var(--line-strong); font-size: 15.5px; line-height: 1.35; color: var(--ink); }
.pt-ledger li:last-child { border-bottom: 0; }
.pt-check { flex: none; width: 17px; height: 16px; stroke: var(--leaf); stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.pt-check path { stroke-dasharray: 1; stroke-dashoffset: 1; }
.pt-ledger.in .pt-check path { stroke-dashoffset: 0; transition: stroke-dashoffset .55s var(--ease) calc(.14s + var(--i, 0) * .09s); }
.no-js .pt-check path { stroke-dashoffset: 0; }
.pt-ticket-foot { display: flex; justify-content: space-between; gap: 16px; margin: 0; padding: 12px 14px 10px; border-top: 1.5px solid var(--forest); font: 500 11px / 1.3 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--stone); }
.pt-ticket-foot .money { font-size: 11px; letter-spacing: .08em; color: var(--forest); }

@media (max-width: 900px) {
  .pt-pioneer-stage { grid-template-columns: minmax(0, 1fr); }
  .pt-pioneer-copy { grid-column: 1; grid-row: 1; padding: 0; max-width: none; }
  .pt-pioneer-photo { grid-column: 1; grid-row: 2; align-self: auto; min-height: 0; aspect-ratio: 16 / 10; margin-top: clamp(28px, 5vw, 44px); }
  .pt-ticket-pioneer { grid-column: 1; grid-row: 3; align-self: auto; margin: -52px 0 0 clamp(16px, 6vw, 60px); }
  .pt-pioneer-cta { grid-row: 4; }
}

/* ---------- The Pioneer Fund ---------- */
.pt-fund { position: relative; padding: calc(var(--sect) * 1) 0; color: #fff; isolation: isolate; overflow: hidden; background: var(--forest); }
.pt-fund-media { position: absolute; inset: 0; z-index: -2; }
.pt-fund-media img { width: 100%; height: 100%; object-fit: cover; }
.pt-fund-scrim { position: absolute; inset: 0; z-index: -1; background: linear-gradient(100deg, rgba(18,56,42,.92) 35%, rgba(18,56,42,.45)); }
.pt-fund-grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); gap: clamp(36px, 6vw, 96px); align-items: center; }
/* the copy spreads down its column so its closing line sits level with the foot of the card,
   instead of leaving the dark half of the band empty */
.pt-fund-copy { display: flex; flex-direction: column; }
.pt-fund h2 { font-size: var(--t-64); }
.pt-fund .lede { color: rgba(255,255,255,.88); margin-top: 18px; }
.pt-fund-copy p:not(.lede):not(.pt-fund-close) { margin-top: 16px; color: rgba(255,255,255,.72); }
.pt-fund-quote { font-style: italic; font-size: var(--t-36); line-height: 1.15; color: var(--sprout); margin: clamp(32px, 4vw, 52px) 0 0; max-width: 18ch; }
.pt-fund-side { padding-top: 8px; }
.pt-ticket-fund { transform: rotate(.7deg); box-shadow: 10px 10px 0 rgba(6, 18, 12, .55); }
.pt-ticket-fund:hover { transform: rotate(.7deg) translateY(-3px); box-shadow: 13px 13px 0 rgba(6, 18, 12, .62); }
.pt-fund-close { margin-top: auto; padding-top: clamp(28px, 3vw, 40px); font-family: var(--sans); font-weight: 500; font-size: var(--t-22); color: var(--sprout); max-width: 26ch; }
@media (max-width: 900px) { .pt-fund-grid { grid-template-columns: 1fr; } .pt-fund-side { padding-top: clamp(30px, 6vw, 48px); } .pt-fund-close { padding-top: 24px; } }

/* ---------- Partner marks ---------- */
.pt-partners { padding: calc(var(--sect) * .5) 0; }

/* ---------- Close ---------- */
.pt-cta-line { margin-top: 18px; color: rgba(255,255,255,.82); max-width: 46em; margin-inline: auto; }

@media (prefers-reduced-motion: reduce) {
  .pt-stamp, .pt-roles-thread .pt-march { animation: none; }
  .pt-check path { stroke-dashoffset: 0; }
}
