/* ==========================================================================
   TPB proof wall - styles for /assets/js/proof.js
   --------------------------------------------------------------------------
   Scoped under .tpb-proof, which the script adds. The video lightbox and the
   full-review modal are styled by testimonials.css and reviews.css, so a page
   loads all three.

   Theme it from the section around it:
     --pf-ink, --pf-muted, --pf-line, --pf-card, --pf-accent, --pf-gap
   ========================================================================== */
.tpb-proof {
  --pf-ink: var(--lt-ink, #0B1B2B);
  --pf-muted: var(--lt-muted, #56697C);
  --pf-line: var(--lt-line, #E4EBF2);
  --pf-card: var(--lt-bg-2, #fff);
  --pf-accent: var(--cyan-ink, #015AFF);
  --pf-gap: 20px;
  --pf-radius: 14px;
}

.tpb-proof .pf-wall { display: grid; grid-template-columns: repeat(var(--pf-cols, 3), minmax(0, 1fr)); gap: var(--pf-gap); align-items: start; }
.tpb-proof .pf-col { display: flex; flex-direction: column; gap: var(--pf-gap); min-width: 0; }

/* ---- the card, both kinds ---- */
.tpb-proof .pf-card { position: relative; margin: 0; display: flex; flex-direction: column; background: var(--pf-card); border: 1px solid var(--pf-line); border-radius: var(--pf-radius); box-shadow: var(--shadow-lt, 0 18px 44px -22px rgba(15, 40, 70, .22)); overflow: hidden; cursor: pointer; transition: transform .18s ease, box-shadow .2s ease; }
.tpb-proof .pf-card:hover { transform: translateY(-2px); box-shadow: 0 22px 48px -22px rgba(15, 40, 70, .32); }
.tpb-proof .pf-card:has(.pf-hit:focus-visible) { box-shadow: 0 0 0 3px var(--pf-accent); }
@media (prefers-reduced-motion: reduce) { .tpb-proof .pf-card, .tpb-proof .pf-card:hover { transition: none; transform: none; } }

/* The whole card is one target. The real control is a button inside it; its
   ::after stretches over the card, so the text stays selectable markup and
   the accessible name stays on a button. */
.tpb-proof .pf-hit { font: inherit; background: none; border: 0; padding: 0; margin: 0; color: inherit; cursor: pointer; }
.tpb-proof .pf-hit::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.tpb-proof .pf-hit:focus-visible { outline: none; }
.tpb-proof .pf-sr { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.tpb-proof .pf-text { margin: 0; color: var(--pf-ink); }
.tpb-proof .pf-text p { margin: 0; font-size: 17px; line-height: 1.5; }

.tpb-proof .pf-who { display: flex; align-items: center; gap: 10px; margin: 0; }
.tpb-proof .pf-who img { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.tpb-proof .pf-who b { display: block; font-size: 14px; font-weight: 700; line-height: 1.3; color: var(--pf-ink); }
.tpb-proof .pf-who span span, .tpb-proof .pf-video .pf-who span { display: block; font-size: 13px; line-height: 1.3; color: var(--pf-muted); }

/* ---- video ---- */
.tpb-proof .pf-thumb { position: relative; flex-shrink: 0; aspect-ratio: 16 / 9; overflow: hidden; background: linear-gradient(135deg, #13293F, #0A1726); }
.tpb-proof .pf-thumb img { width: 100%; height: 100%; display: block; object-fit: contain; }
.tpb-proof .pf-thumb.is-still img { object-fit: cover; }
/* A 9:16 Summit still cropped to 16:9 keeps under a third of its height;
   centred, that band is the chest. 14% was set by eye across all fifteen
   portrait stills: 22% took the top of most heads, 8% took the chins of the
   people standing lower in frame (Pagan Crane, Josh, Dave). */
.tpb-proof .pf-thumb.is-still.is-portrait img { object-position: center 14%; }
.tpb-proof .pf-thumb::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10, 23, 38, 0) 55%, rgba(10, 23, 38, .55)); pointer-events: none; }
.tpb-proof .pf-play { position: absolute; left: 50%; top: 50%; z-index: 1; width: 56px; height: 56px; margin: -28px 0 0 -28px; display: grid; place-items: center; border-radius: 50%; background: rgba(255, 255, 255, .95); box-shadow: 0 8px 24px rgba(0, 0, 0, .35); transition: transform .18s ease; }
.tpb-proof .pf-play svg { width: 24px; height: 24px; margin-left: 3px; fill: var(--pf-accent); }
.tpb-proof .pf-card:hover .pf-play { transform: scale(1.08); }
.tpb-proof .pf-dur { position: absolute; right: 10px; bottom: 10px; z-index: 1; display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 700; color: #fff; background: rgba(10, 23, 38, .78); padding: 3px 8px 3px 5px; border-radius: 4px; }
.tpb-proof .pf-dur svg { width: 14px; height: 14px; fill: currentColor; }
.tpb-proof .pf-video .pf-body { display: flex; flex-direction: column; gap: 14px; padding: 18px 20px 20px; }
.tpb-proof .pf-video .pf-text p { font-weight: 600; }
.tpb-proof .pf-video .pf-who { flex-direction: column; align-items: flex-start; gap: 0; }
/* Its button has no visible label, so it covers the card itself rather than
   sitting in the flex column and adding an empty gap. */
.tpb-proof .pf-video .pf-hit { position: absolute; inset: 0; z-index: 1; }
.tpb-proof .pf-video .pf-hit::after { content: none; }

/* ---- Google review ---- */
.tpb-proof .pf-review { gap: 14px; padding: 20px 20px 16px; }
.tpb-proof .pf-src { display: flex; align-items: center; justify-content: space-between; }
.tpb-proof .pf-stars { display: inline-flex; gap: 2px; }
.tpb-proof .pf-stars svg { width: 16px; height: 16px; fill: #FBBC05; }
/* The highlighter: the one line in the review that is the result. Same yellow
   as the review component's, so the two walls read as one system. */
.tpb-proof mark.pf-hl { background: #FFF06A; color: inherit; padding: 1px 2px; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
/* data-fonts="3": normal, bold, and bold plus highlight (proof.js emphasise) */
.tpb-proof.pf-fonts3 mark.pf-hl, .tpb-proof.pf-fonts3 b.pf-b { font-weight: 700; }
.tpb-proof .pf-read { align-self: flex-start; font-size: 14px; font-weight: 700; color: var(--pf-accent); padding: 6px 0; }
.tpb-proof .pf-card:hover .pf-read { text-decoration: underline; }

/* ---- member win (Facebook community / Slack wins channel; data-community) ----
   Typed out from the screenshot so it reads on a phone. Same frame as a
   review, with the source named in words next to its mark. */
.tpb-proof .pf-win { gap: 14px; padding: 20px 20px 16px; }
.tpb-proof .pf-win .pf-src { justify-content: flex-start; gap: 8px; }
.tpb-proof .pf-src-label { font-size: 13px; font-weight: 600; color: var(--pf-muted); line-height: 1.3; }
.tpb-proof .pf-fb, .tpb-proof .pf-slack, .tpb-proof .pf-mic, .tpb-proof .pf-coach { flex-shrink: 0; }

/* ---- a coach's win as a Slack message (data-wins="slack") ----
   Slack's own shape: a rounded-square avatar, the poster's name in bold with
   where it was posted beside it, and the message under the name, all in one
   column right of the avatar. */
.tpb-proof .pf-slackmsg { padding: 18px 20px 16px; }
.tpb-proof .pf-msg { display: flex; align-items: flex-start; gap: 12px; }
.tpb-proof .pf-ava { flex-shrink: 0; width: 40px; height: 40px; border-radius: 9px; background: #0B1B2B; color: #fff; font-weight: 800; font-size: 18px; line-height: 40px; text-align: center; }
.tpb-proof .pf-ava img { display: block; width: 100%; height: 100%; border-radius: 9px; object-fit: cover; object-position: center 20%; }
.tpb-proof .pf-msg-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.tpb-proof .pf-msg-head { display: flex; flex-wrap: wrap; align-items: baseline; column-gap: 8px; line-height: 1.3; }
.tpb-proof .pf-msg-head b { font-size: 16px; font-weight: 800; color: var(--pf-ink); }
.tpb-proof .pf-msg-head span { font-size: 13px; color: var(--pf-muted); }
.tpb-proof .pf-slackmsg .pf-who { margin-top: 8px; }
.tpb-proof .pf-slackmsg .pf-read { margin-top: 12px; margin-left: 52px; align-self: flex-start; }

/* The original screenshot, opened from "See the original post". */
/* margin:auto is what centres a modal dialog; pages that reset *{margin:0} pinned it top left (17 Nov). */
.pf-shot { margin: auto; border: 0; padding: 0; border-radius: 14px; max-width: min(92vw, 720px); max-height: 88vh; background: #fff; box-shadow: 0 24px 60px rgba(11, 27, 43, .35); }
.pf-shot::backdrop { background: rgba(11, 27, 43, .7); }
.pf-shot img { display: block; width: 100%; height: auto; max-height: 88vh; object-fit: contain; }
.pf-shot-x { position: absolute; top: 8px; right: 8px; width: 40px; height: 40px; border: 0; border-radius: 50%; background: rgba(11, 27, 43, .75); color: #fff; font-size: 24px; line-height: 1; cursor: pointer; }

/* ---- doodles (data-doodles; PROTOTYPE, Ben 6 Nov) ----
   TPB-blue marker on top of the card: a lopsided circle round a short line, a
   plain straight underline under a long one, and with "full" a handwritten note and an arrow
   above the quote. The member's words are never changed; the note is ours and
   decorative (aria-hidden). Blue is the marker (Clark, 6 Nov: TPB blue, not red; straight underline,
   not a squiggle), yellow stays the highlighter. */
.tpb-proof { --pf-marker: #015AFF; }
.tpb-proof .pf-dd { position: relative; }
.tpb-proof .pf-dd-circle { white-space: nowrap; }
.tpb-proof .pf-dd-circle::after {
  content: ""; position: absolute; left: -9px; right: -9px; top: -7px; bottom: -7px; pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 60' preserveAspectRatio='none'%3E%3Cpath d='M18 12C60 2 150 3 186 14C204 22 196 46 150 54C100 61 34 58 12 44C-4 33 6 16 40 9' fill='none' stroke='%23015AFF' stroke-width='3.2' stroke-linecap='round'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
}
/* mark.pf-hl sets its background as a shorthand, so on a highlighted line the
   underline has to out-rank it and add itself on top of the yellow. */
.tpb-proof .pf-dd-under, .tpb-proof mark.pf-hl.pf-dd-under {
  padding-bottom: 5px;
  background-image: linear-gradient(var(--pf-marker), var(--pf-marker));
  background-repeat: no-repeat; background-position: left bottom; background-size: 100% 3px;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.tpb-proof .pf-card.has-doodle { overflow: visible; }
.tpb-proof .pf-card.has-doodle .pf-thumb { border-radius: var(--pf-radius) var(--pf-radius) 0 0; }
/* The note straddles the card's top edge (or the foot of a video thumbnail),
   half outside the frame; aim() in proof.js places it and the arrow. */
.tpb-proof .pf-dd-note { position: absolute; left: 0; top: -14px; z-index: 3; pointer-events: none; color: var(--pf-marker); white-space: nowrap; }
.tpb-proof .pf-dd-note span { display: block; font-family: 'Caveat', 'Bradley Hand', 'Segoe Print', cursive; font-weight: 700; font-size: 26px; line-height: 1.1; transform: rotate(var(--pf-dd-tilt, -3deg)); }
.tpb-proof .pf-dd-arrow { position: absolute; left: 0; top: 0; z-index: 3; overflow: visible; pointer-events: none; color: var(--pf-marker); }
.tpb-proof .pf-dd-arrow path { fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }

/* ---- load more ---- */
.tpb-proof .pf-foot { display: flex; justify-content: center; margin-top: 28px; }
.tpb-proof .pf-load { font: inherit; font-size: 16px; font-weight: 700; color: var(--pf-ink); background: var(--pf-card); border: 1px solid var(--pf-line); border-radius: 10px; padding: 14px 28px; min-height: 48px; cursor: pointer; transition: border-color .15s ease; }
.tpb-proof .pf-load:hover { border-color: var(--pf-ink); }
.tpb-proof .pf-load:focus-visible { outline: 3px solid var(--pf-accent); outline-offset: 2px; }

@media (max-width: 560px) {
  .tpb-proof { --pf-gap: 16px; }
}

/* ---- mobile body-copy floor ---- */
@media (max-width: 820px) {
  .tpb-proof .pf-text p { font-size: 18px; }
}
