/* Profile panel (parts/sections/scene/profile.php), local preview 2026-11-29, round 2.
   A person scene with a full portrait: the photo sits in the site's image-card frame (Mist,
   white inside ring, big soft shadow, as .imgcard__frame in components.css) and a solid white
   card of facts overlaps it, over a soft lavender halo. Existing tokens only.
   Contrast measured from pixels: name (white) and role (#D5D8FF) on the caption scrim 12:1 or
   more; labels (ink 68%) on the white facts card 6.7:1; values (ink) 18:1. */
.pf { position: relative; display: flex; flex-direction: column; align-items: center; width: 100%; isolation: isolate; }
/* Soft halo only. No horizontal inset, so it never widens the page. */
.pf__halo {
	position: absolute; z-index: -1; inset: -12% 0;
	background:
		radial-gradient(closest-side at 66% 42%, rgba(131, 138, 236, .30), rgba(131, 138, 236, 0) 100%),
		radial-gradient(34% 30% at 30% 66%, rgba(1, 14, 208, .08), rgba(1, 14, 208, 0) 100%);
	pointer-events: none;
}
/* Portrait in the image-card frame: 10px padding, 22px outer and 12px inner radius on phones,
   14px padding, 28px outer and 14px inner radius from 768 (same values as .imgcard__frame). */
.pf__portrait {
	--pf-pad: 10px; --pf-r-in: 12px;
	position: relative; margin: 0; width: 100%; max-width: 420px; overflow: hidden;
	padding: var(--pf-pad); border-radius: 22px;
	background: var(--c-mist); box-shadow: var(--ring-card), var(--sh-big);
}
.pf__img {
	display: block; width: 100%; height: auto; aspect-ratio: 1 / 1;
	object-fit: cover; object-position: 50% 3%;
	border-radius: var(--pf-r-in); background: var(--c-night);
}
/* Scrim and caption, clipped to the inner image radius. */
.pf__cap {
	position: absolute; inset: auto var(--pf-pad) var(--pf-pad); z-index: 1;
	display: flex; flex-direction: column; gap: 2px;
	padding: 48px 16px 34px; /* the bottom 26px of the image sit under the facts card on phones */
	border-radius: 0 0 var(--pf-r-in) var(--pf-r-in);
	background: linear-gradient(180deg, rgba(7, 10, 36, 0), rgba(7, 10, 36, .78) 46%, rgba(7, 10, 36, .96));
	color: var(--c-white);
}
.pf__name { font: var(--fw-medium) 20px/26px var(--f-head); letter-spacing: -.3px; }
.pf__role { font: var(--fw-medium) 13px/18px var(--f-body); color: #D5D8FF; }
/* Facts: solid white card, no border, big soft shadow. */
.pf__facts {
	position: relative; z-index: 2; display: flex; flex-direction: column;
	width: calc(100% - 20px); max-width: 400px; margin: -36px 0 0; padding: 2px 16px;
	border-radius: var(--r-card); background: var(--c-white); box-shadow: var(--sh-big);
}
.pf__fact { display: flex; flex-direction: column; gap: 0; padding: 6px 0; }
.pf__fact + .pf__fact { border-top: 1px solid var(--ink-10); }
.pf__fact dt { font: var(--fw-medium) 12px/16px var(--f-body); letter-spacing: .8px; text-transform: uppercase; color: var(--ink-68); }
.pf__fact dd { margin: 0; min-width: 0; overflow-wrap: anywhere; font: var(--fw-medium) 14px/20px var(--f-body); color: var(--c-ink); }
/* Linked value: underlined, with the focus ring hugging the text. The 44px tap area is a
   pseudo-element that starts at the top of the value and grows downward only, so neither the
   hit area nor the ring ever covers the label above. */
.pf__link {
	position: relative; display: inline-block;
	color: inherit; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px;
}
.pf__link::after { content: ""; position: absolute; top: 0; right: -8px; bottom: -24px; left: -8px; }
.pf__link:focus-visible { outline-offset: 1px; }
/* The linked row keeps 6px between label and value, so the 3px ring (1px offset) stays below the label. */
.pf__fact:has(.pf__link) { row-gap: 6px; }
@media (max-width: 599px) { .pf__fact:has(.pf__link) { padding-top: 4px; } }
.pf__link:hover { color: var(--c-blue); }

/* Stacked hero (under 1024px): the halo does not reach up over the hero buttons. */
@media (max-width: 1023px) {
	.pf__halo { inset: 0 0 -10%; }
}

/* Narrow phones: the role wraps to two lines, so the caption sits lower (a shallower overlap) to
   stay clear of the chin. */
/* From 360px a slightly wider crop (20:19); the caption still clears the chin. */
@media (min-width: 360px) and (max-width: 599px) {
	.pf__img { aspect-ratio: 20 / 19; }
}
@media (max-width: 399px) {
	.pf__facts { margin-top: -26px; }
	.pf__cap { padding: 40px 14px 24px; }
	.pf__name { font-size: 18px; line-height: 24px; }
	.pf__role { font-size: 12px; line-height: 16px; }
}

/* From 600px the two cards overlap side by side: facts on the left, portrait on the right.
   Three tracks: the middle one (56px) is the overlap, kept clear of the face. */
@media (min-width: 600px) {
	.pf { display: grid; grid-template-columns: minmax(0, 1fr) 56px minmax(0, 1fr); align-items: center; max-width: 600px; margin-inline: 0 auto; }
	.pf__portrait { grid-area: 1 / 2 / 2 / 4; max-width: none; }
	.pf__img { aspect-ratio: 4 / 5; object-position: 50% 10%; }
	.pf__facts { grid-area: 1 / 1 / 2 / 3; width: auto; max-width: none; margin: 0; padding: 8px 22px; }
	.pf__fact { gap: 2px; padding: 13px 0; }
	.pf__fact dd { font-size: 15px; line-height: 22px; }
	.pf__name { font-size: 22px; line-height: 28px; letter-spacing: -.4px; }
	.pf__role { font-size: 14px; line-height: 20px; }
	/* The caption starts to the right of the overlap track, clear of the facts card. */
	.pf__cap { gap: 4px; padding: 72px 18px 18px 62px; }
}
@media (min-width: 768px) {
	.pf__portrait { --pf-pad: 14px; --pf-r-in: 14px; border-radius: 28px; }
}
@media (min-width: 1200px) {
	.pf__name { font-size: 24px; line-height: 30px; }
}
/* 1024 to 1199px, person scene only: the copy column keeps the two hero buttons on one row
   (they need 426px), the panel keeps its side-by-side arrangement, and the H1 is smaller.
   The facts rows tighten so the card stays shorter than the portrait. */
@media (min-width: 1024px) and (max-width: 1199px) {
	.hero.hero--scene-right:has([data-scene="person"] .pf) .hero__inner { grid-template-columns: minmax(0, .92fr) minmax(0, 1fr); column-gap: 40px; }
	.hero.hero--scene-right:has([data-scene="person"] .pf) .h1 { font-size: 44px; line-height: 50px; }
	.pf { grid-template-columns: minmax(0, 200fr) 48px minmax(0, 223fr); }
	.pf__facts { padding: 6px 20px; }
	.pf__fact { padding: 10px 0; }
	.pf__fact dd { font-size: 14px; line-height: 20px; }
	.pf__cap { padding: 56px 16px 16px 50px; }
	.pf__name { font-size: 20px; line-height: 26px; letter-spacing: -.3px; }
	.pf__role { font-size: 13px; line-height: 18px; }
}

/* Entrance, after the hero's own reveal of the visual. The portrait may be the LCP element, so it
   moves with transform only; the facts card and its rows fade in. Everything ends by 1.5s.
   motion.css removes every animation under reduced motion; the rule below repeats that here. */
.hero [data-scene="person"] .pf__portrait { animation: pf-settle 900ms var(--ease-out-expo) 260ms both; }
.hero [data-scene="person"] .pf__facts { animation: pf-slide 800ms var(--ease-out-expo) 420ms both; }
.hero [data-scene="person"] .pf__fact { animation: pf-fade 500ms var(--ease-out-quart) both; animation-delay: calc(640ms + var(--i, 0) * 80ms); }
@keyframes pf-settle { from { transform: translateY(14px) scale(.975); } to { transform: none; } }
@keyframes pf-slide { from { opacity: 0; transform: translateX(-18px); } to { opacity: 1; transform: none; } }
@keyframes pf-fade { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
	.hero [data-scene="person"] .pf__portrait, .hero [data-scene="person"] .pf__facts, .hero [data-scene="person"] .pf__fact { animation: none; }
}

/* ---------------------------------------------------------------- Same page, below the hero
   Scoped to the one page that renders the profile panel (main:has(.pf)); no other page prints
   .pf, so these rules match nothing elsewhere. */

/* "What he writes about": heading and chips on one row from 768px. */
@media (min-width: 768px) {
	main:has(.pf) .chips-card { flex-direction: row; align-items: center; justify-content: space-between; gap: 24px 40px; padding: 22px 32px; }
	main:has(.pf) .chips-card > .head--chips { flex: 0 0 auto; gap: 6px; }
	main:has(.pf) .chips-card .head--chips .h2 { font-size: 24px; line-height: 30px; letter-spacing: -.5px; }
	main:has(.pf) .chips-card > .chips-cols { flex: 0 1 auto; min-width: 0; display: block; }
}

/* "Selected articles" on phones: each card is one row, a 96x72 thumbnail on the left and the
   text on the right. The whole card stays one link (the stretched .card-link). Below 560px only:
   from 560px the site already sets the cards two-up (zz-zm-layout.css). */
@media (max-width: 559px) {
	main:has(.pf) .posts { gap: 10px; }
	main:has(.pf) .post--img {
		display: grid; grid-template-columns: 96px minmax(0, 1fr); grid-template-rows: auto 1fr; column-gap: 14px; row-gap: 4px;
		align-items: start; min-height: 92px; padding: 10px 12px 10px 10px;
	}
	main:has(.pf) .post--img .post__media { grid-area: 1 / 1 / 3 / 2; width: 96px; height: 72px; border-radius: 10px; }
	main:has(.pf) .post--img .post__body { grid-area: 1 / 2 / 2 / 3; min-width: 0; gap: 6px; padding: 0; }
	main:has(.pf) .post--img .post__top { gap: 8px; }
	main:has(.pf) .post--img .post__top .pill { min-width: 0; }
	main:has(.pf) .post--img .post__top .arrow-ne { flex: none; }
	main:has(.pf) .post--img .post__t { font-size: 16px; line-height: 21px; }
	main:has(.pf) .post--img .post__meta { grid-area: 2 / 2 / 3 / 3; padding: 0; }
}
@media (max-width: 359px) {
	main:has(.pf) .post--img { grid-template-columns: 84px minmax(0, 1fr); column-gap: 12px; padding-right: 10px; }
	main:has(.pf) .post--img .post__media { width: 84px; height: 63px; }
}
