/* Team profiles (/team/<slug>): built by scripts/build_team.py.
   Layout and hover behaviour follow alexffb.com (black-and-white photos that turn to colour on hover,
   floating dock, words lit by the scroll, outlined giant words, film-strip gallery). Branding is AP's:
   menu, lettering (titles in Inter Display Bold, highlights in Instrument Serif Italic, text in Inter; the name inverted over the
   photo like the AP home), contact block and footer. --accent is the person's area colour. */
@font-face { font-family: "Host Grotesk"; font-weight: 400; font-display: swap; src: url(/assets/fonts/font-6be6f339.woff2) format("woff2"); }
@font-face { font-family: "Host Grotesk"; font-weight: 500; font-display: swap; src: url(/assets/fonts/font-c67a7cfb.woff2) format("woff2"); }
@font-face { font-family: "Instrument Serif"; font-style: italic; font-display: swap; src: url(/assets/fonts/font-a003af28.woff2) format("woff2"); }
@font-face { font-family: "Inter Display"; font-weight: 100 900; font-display: swap; src: url(/assets/fonts/inter-display-latin.woff2) format("woff2"); }
/* Inter (variable, optical-size axis): body text at its normal cut, titles at the Display cut (opsz 32). */
@font-face { font-family: "Inter"; font-weight: 100 900; font-display: swap; src: url(/assets/fonts/inter-display-latin.woff2) format("woff2"); }
:root {
  color-scheme: dark; --bg: #000; --grey: #bdbdbd; --dim: #333; --pill: #1c1c1c; --line: rgba(250, 250, 250, .12);
  --other: #007fff; --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif; --display: "Inter Display", "Inter", system-ui, sans-serif; --serif: "Instrument Serif", Georgia, serif;
  --ease: cubic-bezier(.2, .7, .2, 1); --gutter: clamp(16px, 4.9vw, 70px); --max: 1300px;
}
html[style*="#007fff"] { --other: #ee620d; }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--grey); font: 17px/1.6 var(--sans); overflow-x: hidden; }
a { color: #fff; text-underline-offset: 3px; transition: color .3s; }
a:hover { color: var(--accent); }
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3 { color: #fff; font-weight: 400; }
h2, h3, .tm-foot-h, .tm-manifesto { text-wrap: balance; }
:target { scroll-margin-top: 24px; }
.tm-wrap, .tm-about, .tm-offer, .tm-work, .tm-cv { max-width: calc(var(--max) + 2 * var(--gutter)); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }

/* Photos: black and white by default, colour on hover (alexffb.com). The colour copy sits on top and fades in. */
.tm-bw { filter: grayscale(1) contrast(1.08); }
.tm-color { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .7s var(--ease); }

/* ---- AP menu ---------------------------------------------------------------- */
.tm-top {
  position: absolute; z-index: 20; top: 0; left: 50%; transform: translateX(-50%); width: min(100%, calc(var(--max) + 2 * var(--gutter)));
  display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 22px var(--gutter) 0;
}
.tm-top::after { content: ""; position: absolute; left: var(--gutter); right: var(--gutter); bottom: -14px; border-bottom: 1px solid var(--line); }
.tm-logo { display: inline-flex; align-items: center; min-height: 44px; }
.tm-logo img { width: 76px; }
.tm-top ul { list-style: none; display: flex; gap: 4px 40px; margin: 0; padding: 0; }
.tm-top li a { display: inline-flex; align-items: flex-start; min-height: 44px; padding-top: 12px; color: #fff; font-size: 13px; letter-spacing: -.01em; text-decoration: none; }
.tm-top sup { margin-left: 3px; font-size: 8px; color: var(--grey); }
.tm-top li a:hover { color: var(--accent); }

/* ---- hero: the photo, and the name inverted over it --------------------------------- */
.tm-hero {
  position: relative; isolation: isolate; overflow: hidden; display: flex; align-items: flex-end; justify-content: center;
  min-height: 100vh; min-height: 100svh; padding: 0 var(--gutter) clamp(120px, 16vh, 170px);
  background: radial-gradient(110% 75% at 50% 32%, #6c6c6c 0%, #343434 38%, #101010 70%, #000 100%);
}
.tm-hero::before { /* the person's colour, as a back light; brighter on hover */
  content: ""; position: absolute; z-index: -2; left: 50%; top: 4%; width: min(560px, 90vw, 60vh); aspect-ratio: 1; transform: translateX(-50%);
  background: radial-gradient(closest-side, var(--accent), transparent 72%); opacity: .2; filter: blur(40px); transition: opacity .8s var(--ease);
}
/* The photo is sized by the screen height, so the head is never cut and the name sits on the chest. */
.tm-photo { position: absolute; z-index: -1; left: 50%; bottom: 0; height: min(94%, 1240px); aspect-ratio: 800 / 1062; transform: translateX(-50%); will-change: transform; }
/* The photos are cut at the shoulders: the sides and the bottom fade out, so no edge shows. */
.tm-photo img { position: absolute; inset: 0; width: 100%; height: 100%;
  -webkit-mask-image: linear-gradient(180deg, #000 58%, transparent 94%), linear-gradient(90deg, transparent 0%, #000 20%, #000 80%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(180deg, #000 58%, transparent 94%), linear-gradient(90deg, transparent 0%, #000 20%, #000 80%, transparent 100%);
  mask-composite: intersect; }
/* The liquid reveal covers the whole hero: the person in original colours, the backdrop in the person's colour. */
.tm-liquid { position: absolute; z-index: -1; inset: 0; width: 100%; height: 100%; pointer-events: none; }
/* Without WebGL (or on touch screens): the whole photo fades to colour on hover. */
.tm-hero:not(.has-liquid):hover .tm-color, .tm-hero:not(.has-liquid):focus-within .tm-color { opacity: 1; }
.tm-hero:hover::before { opacity: .42; }
.tm-name {
  position: relative; margin: 0; width: 100%; max-width: var(--max); text-align: center; white-space: nowrap;
  font: 700 clamp(34px, 9.4vw, 176px)/.9 "Inter Display", "Inter", var(--sans); font-variation-settings: "opsz" 32;
  letter-spacing: -.045em; text-transform: uppercase; color: #fff; mix-blend-mode: difference;
}
@media (forced-colors: active) { .tm-name { mix-blend-mode: normal; } }
.js .tm-name { animation: tm-rise 1.1s var(--ease) both; }
.js .tm-photo .tm-bw { animation: tm-settle 1.6s var(--ease) both; }
@keyframes tm-rise { from { opacity: 0; transform: translateY(40px); } to { opacity: 1; transform: none; } }
@keyframes tm-settle { from { opacity: 0; transform: scale(1.05); } to { opacity: 1; transform: none; } }

/* ---- floating dock (alexffb.com) -------------------------------------------------- */
.tm-dock { position: fixed; z-index: 40; left: 50%; bottom: 20px; transform: translateX(-50%); display: flex; gap: 8px; }
.tm-dock-btn {
  display: inline-flex; align-items: center; gap: 14px; min-height: 58px; padding: 0 26px; border-radius: 999px;
  background: linear-gradient(180deg, #2a2a2a, #191919); color: #f2f2f2; text-decoration: none;
  font: 400 15px/1 var(--sans); letter-spacing: -.01em; white-space: nowrap;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(255, 255, 255, .08); transition: transform .3s var(--ease), color .3s;
}
.tm-dock-main { padding-left: 5px; }
.tm-short { display: none; }
.tm-dot { display: inline-grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: var(--accent); color: #fff; transition: transform .5s var(--ease); }
.tm-dock-btn:hover { transform: translateY(-2px); color: var(--accent); }
.tm-dock-main:hover { color: #fff; }
.tm-dock-main:hover .tm-dot { transform: rotate(90deg); }

/* ---- (old story styles removed) ----------------------------------------------------------------------- */
.tm-w { transition: color .35s; }
.js .tm-manifesto .tm-w { color: var(--dim); }
.js .tm-manifesto .tm-w.on { color: #fff; }
.tm-cap-name { font-size: 26px; letter-spacing: -.03em; color: #fff; }
.tm-cap-role { font: italic 15px/1 var(--serif); color: #e6e6e6; }
.tm-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: clamp(72px, 9vw, 128px) 0 0; border-top: 1px solid var(--line); }
.tm-fact { padding: 28px 24px 8px 0; border-right: 1px solid var(--line); }
.tm-fact:last-child { border-right: 0; }
.tm-fact + .tm-fact { padding-left: 24px; }
.tm-fact dt { font-size: clamp(48px, 5.4vw, 84px); line-height: 1; letter-spacing: -.06em; color: #fff; transition: color .4s; }
.tm-fact:hover dt { color: var(--accent); }
.tm-fact dd { margin: 12px 0 0; font-size: 15px; line-height: 1.45; }

/* ---- lists: how I can help, portfolio ------------------------------------------------ */
.tm-offer, .tm-work, .tm-cv { padding-top: clamp(80px, 10vw, 150px); }
.tm-list { list-style: none; margin: 0 auto; padding: 0; max-width: 900px; display: grid; gap: clamp(48px, 6vw, 84px); }
.tm-item { display: grid; grid-template-columns: clamp(48px, 9vw, 96px) 1fr; }
.tm-num { padding-top: 6px; font-size: 15px; color: #8a8a8a; transition: color .3s; }
.tm-item h3 { margin: 0 0 10px; font-size: clamp(22px, 2vw, 28px); line-height: 1.15; letter-spacing: -.035em; transition: color .3s; }
.tm-item:hover h3, .tm-item:hover .tm-num { color: var(--accent); }
.tm-item p { margin: 0; font-size: clamp(16px, 1.3vw, 18px); }
.tm-meta { margin: 0 0 8px !important; font: italic 16px/1.2 var(--serif) !important; color: #e0e0e0; }
.tm-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 56px; margin-top: 24px; padding: 0 26px;
  border: 1px solid rgba(255, 255, 255, .7); border-radius: 999px; color: #fff; text-decoration: none; font-size: 16px; letter-spacing: -.01em;
  transition: background-color .3s, border-color .3s, color .3s;
}
.tm-bar:hover { background: var(--accent); border-color: var(--accent); color: #fff; }

/* ---- giant outlined words, blurred by scroll speed ---------------------------------- */
.tm-outline { margin: 0 0 clamp(40px, 6vw, 96px); overflow: hidden; font: 500 clamp(56px, 14.5vw, 240px)/.9 var(--sans); letter-spacing: -.06em; text-align: center; white-space: nowrap; }
.tm-outline span { display: inline-block; color: transparent; -webkit-text-stroke: clamp(1.5px, .2vw, 3px) #fff; will-change: transform, filter; }
@supports not (-webkit-text-stroke: 1px #fff) { .tm-outline span { color: #fff; } }

/* ---- film-strip gallery: moves on its own, colour on hover (alexffb.com) ------------------- */
.tm-gallery { margin-top: clamp(80px, 10vw, 150px); overflow: hidden; }
.tm-strip { display: flex; width: max-content; animation: tm-marquee 22s linear infinite; }
.tm-strip ul { display: flex; gap: 0; margin: 0; padding: 0; list-style: none; }
.tm-strip li { width: clamp(180px, 20vw, 280px); }
.tm-strip img { width: 100%; filter: grayscale(1); transition: filter .6s var(--ease), transform .6s var(--ease); }
.tm-strip li:hover img { filter: grayscale(0); transform: scale(1.03); }
/* The strip stops only while the visitor holds a photo (mouse button or finger down), or with "Pause animations". */
.tm-strip.is-held, html.ap-motion-paused .tm-strip { animation-play-state: paused; }
.tm-strip { touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.tm-strip img { -webkit-user-drag: none; pointer-events: auto; }
@keyframes tm-marquee { to { transform: translateX(-50%); } }

/* ---- CV: organisation tabs, logos in colour when chosen (alexffb.com) ------------------- */
.tm-tabs { max-width: 1100px; margin: 0 auto; }
.tm-tabs [role="tablist"] { display: flex; justify-content: center; gap: clamp(8px, 4vw, 64px); border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.tm-tabs [role="tab"] {
  display: grid; justify-items: center; gap: 6px; min-width: 150px; padding: 8px 12px 22px; border: 0; border-bottom: 2px solid transparent; margin-bottom: -1px;
  background: none; color: #8a8a8a; font: 500 12px/1.3 var(--sans); cursor: pointer; transition: color .3s, border-color .3s;
}
.tm-logo-org { width: 56px; height: 56px; margin-bottom: 8px; border-radius: 50%; object-fit: cover; background: #fff; filter: grayscale(1); opacity: .55; transition: filter .5s, opacity .5s; }
.tm-tabs [role="tab"]:hover .tm-logo-org, .tm-tabs [role="tab"][aria-selected="true"] .tm-logo-org { filter: none; opacity: 1; }
.tm-tabs [role="tab"][aria-selected="true"] { color: #fff; border-bottom-color: var(--accent); }
.tm-tabs [role="tab"]:hover { color: #fff; }
.tm-org { text-transform: uppercase; letter-spacing: .02em; }
.tm-role { font-weight: 400; color: #8a8a8a; }
.tm-tabs-single [role="tablist"] { border-bottom: 0; }
.tm-panel { display: grid; gap: 40px; max-width: 760px; margin: 0 auto; padding: clamp(36px, 5vw, 64px) 0 0; outline-offset: 8px; }
.tm-period { margin: 0 0 8px; font: italic 17px/1.2 var(--serif); letter-spacing: .06em; color: var(--accent); }
.tm-job h3 { margin: 0 0 10px; font-size: clamp(26px, 2.8vw, 40px); line-height: 1.05; letter-spacing: -.045em; }
.tm-job p:last-child { margin: 0; font-size: 17px; }
.tm-blocks { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 0; max-width: var(--max); margin: clamp(72px, 9vw, 128px) auto 0; border-top: 1px solid var(--line); }
.tm-block { padding: 28px 24px 28px 0; border-bottom: 1px solid var(--line); }
.tm-block ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.tm-block li { display: grid; gap: 2px; font-size: 15px; line-height: 1.45; }
.tm-block strong { font-weight: 500; color: #fff; }

/* ---- contact: AP's "Fale connosco" block ---------------------------------------------- */
.tm-contact { position: relative; isolation: isolate; overflow: hidden; margin-top: clamp(96px, 12vw, 180px); padding: clamp(96px, 12vw, 170px) var(--gutter) clamp(80px, 10vw, 130px); }
.tm-blob { position: absolute; z-index: -1; inset: 0; filter: blur(70px); opacity: .9; }
.tm-blob span { position: absolute; border-radius: 50%; animation: tm-drift 18s ease-in-out infinite alternate; }
.tm-blob span:nth-child(1) { width: 62vw; height: 46vw; left: -12vw; bottom: -18vw; background: var(--accent); }
.tm-blob span:nth-child(2) { width: 46vw; height: 38vw; right: -14vw; top: 10%; background: var(--other); opacity: .75; animation-duration: 22s; }
.tm-blob span:nth-child(3) { width: 40vw; height: 30vw; left: 30vw; top: -10vw; background: #000; animation-duration: 26s; }
@keyframes tm-drift { to { transform: translate(6vw, -4vw) scale(1.12); } }
html.ap-motion-paused .tm-blob span { animation-play-state: paused; }
.tm-contact-in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; max-width: var(--max); margin: 0 auto; align-items: start; }
.tm-contact-text { padding-right: clamp(0px, 4vw, 64px); }
.tm-contact-text h2 { margin: 0 0 18px; font-size: clamp(40px, 4.2vw, 60px); line-height: 1; letter-spacing: -.055em; }
.tm-contact-text p { max-width: 44ch; margin: 0 0 18px; color: #e8e8e8; font-size: 16px; line-height: 1.55; }
.tm-lines { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 4px; }
.tm-lines a { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; font-size: 18px; text-decoration: none; }
.tm-privacy { font-size: 15px !important; color: #cfcfcf !important; }
.tm-social { list-style: none; display: flex; gap: 12px; margin: 0 0 18px; padding: 0; }
.tm-social a { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 8px; }
.tm-map { position: relative; margin: 0; overflow: hidden; border-radius: 18px; }
.tm-map img { width: 100%; aspect-ratio: 16 / 8; object-fit: cover; filter: grayscale(.2); }
.tm-pin { position: absolute; left: 50%; top: 52%; width: 16px; height: 16px; margin: -8px 0 0 -8px; border: 2px solid #fff; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 10px color-mix(in srgb, var(--accent) 30%, transparent); }
.tm-map figcaption { position: absolute; right: 8px; bottom: 6px; padding: 2px 6px; border-radius: 4px; background: rgba(0, 0, 0, .6); font-size: 11px; color: #ddd; }
.tm-form { display: grid; gap: 4px; padding: clamp(28px, 3.4vw, 48px); border-radius: 18px; background: rgba(12, 12, 12, .74); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); }
.tm-form label { margin-top: 14px; font-size: 20px; letter-spacing: -.02em; color: #fff; }
.tm-form input[type="text"], .tm-form input[type="email"], .tm-form textarea {
  width: 100%; padding: 14px 12px; border: 0; border-bottom: 1px solid rgba(255, 255, 255, .25); border-radius: 0;
  background: transparent; color: #fff; font: 16px/1.4 var(--sans); outline: none; transition: border-color .3s;
}
.tm-form textarea { resize: vertical; min-height: 96px; }
.tm-form input::placeholder, .tm-form textarea::placeholder { color: rgba(255, 255, 255, .78); }
.tm-form input:focus, .tm-form textarea:focus { border-bottom-color: var(--accent); }
.tm-send {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 50px; margin-top: 48px; padding: 0 20px;
  border: 1px solid #fff; border-radius: 999px; background: transparent; color: #fff; font: 400 16px/1 var(--sans); cursor: pointer;
  transition: background-color .3s, border-color .3s;
}
.tm-send:hover { background: var(--accent); border-color: var(--accent); }
.tm-send[disabled] { opacity: .6; cursor: progress; }
.tm-status { min-height: 1.5em; margin: 10px 0 0; font-size: 15px; color: #fff; }
.tm-trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* ---- footer: AP's -------------------------------------------------------------------- */
.tm-foot { position: relative; isolation: isolate; overflow: hidden; padding: 0 var(--gutter) 28px; background: #000; }
.tm-foot::before { content: ""; position: absolute; z-index: -1; left: 50%; bottom: -55%; width: 140%; height: 100%; transform: translateX(-50%); background: radial-gradient(closest-side, var(--accent), transparent); opacity: .55; filter: blur(30px); }
.tm-foot-cta { max-width: var(--max); margin: 0 auto; padding: clamp(96px, 12vw, 150px) 0 clamp(80px, 10vw, 120px); border-top: 1px solid var(--line); text-align: center; }
.tm-foot-h { margin: 0 auto; max-width: 22ch; font-size: clamp(30px, 3.6vw, 52px); line-height: 1.08; letter-spacing: -.05em; color: #fff; }
.tm-cycle { position: relative; height: 1.4em; margin: 22px 0 0; font: italic clamp(18px, 1.8vw, 24px)/1.4 var(--serif); color: #dcdcdc; }
.tm-cycle-in span { position: absolute; left: 0; right: 0; opacity: 0; filter: blur(8px); animation: tm-cycle 16s infinite; }
.tm-cycle-in span:nth-child(2) { animation-delay: 4s; }
.tm-cycle-in span:nth-child(3) { animation-delay: 8s; }
.tm-cycle-in span:nth-child(4) { animation-delay: 12s; }
@keyframes tm-cycle { 0%, 100% { opacity: 0; filter: blur(8px); letter-spacing: .08em; } 5%, 22% { opacity: 1; filter: blur(0); letter-spacing: 0; } 27% { opacity: 0; filter: blur(8px); letter-spacing: .08em; } }
html.ap-motion-paused .tm-cycle-in span { animation: none; }
html.ap-motion-paused .tm-cycle-in span:first-child { opacity: 1; filter: none; }
.no-js .tm-cycle-in span:first-child { opacity: 1; filter: none; }
.tm-foot-row { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 12px 32px; max-width: var(--max); margin: 0 auto; padding-top: 24px; border-top: 1px solid var(--line); font-size: 12px; color: #a8a8a8; }
.tm-foot-row p { margin: 12px 0 0; }
.tm-foot-row ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0 36px; }
.tm-foot-row a { display: inline-flex; align-items: center; min-height: 40px; color: #e6e6e6; font-size: 12px; text-decoration: none; }
.tm-foot-row a:hover { color: var(--accent); }


/* ---- CV / business-card layout ------------------------------------------------------- */
.tm-sec, .tm-about { max-width: calc(var(--max) + 2 * var(--gutter)); margin: 0 auto; padding: clamp(80px, 10vw, 140px) var(--gutter) 0; }
/* Section heading: a small Instrument Serif Italic label, then the title in Inter Display Bold. */
.tm-eyebrow { margin: 0 0 14px; font: italic 13px/1.3 var(--serif); letter-spacing: .2em; text-transform: uppercase; color: #e6e6e6; }
.tm-h2 { margin: 0 0 clamp(32px, 4.5vw, 64px); font-size: clamp(34px, 4.4vw, 64px); line-height: 1.02; letter-spacing: -.05em; color: #fff; }
.tm-about-grid { display: grid; grid-template-columns: minmax(0, 420px) minmax(0, 1fr); gap: clamp(32px, 6vw, 96px); align-items: center; }
/* The photo is AP's own team card (Digitalization or Public Funding), with no hover effect. */
.tm-card { position: relative; margin: 0; overflow: hidden; aspect-ratio: 1200 / 1593; background: #000; }
.tm-card-bg, .tm-card-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.tm-card-blue .tm-card-bg { filter: hue-rotate(190deg) saturate(1.15); }
.tm-card-blur { position: absolute; left: 0; right: 0; bottom: 0; height: 30%; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 70%); mask-image: linear-gradient(180deg, transparent, #000 70%); }
.tm-card figcaption { position: absolute; left: 30px; right: 30px; bottom: 26px; display: grid; gap: 6px; }
.tm-cap-name { font-size: 25px; line-height: 1.1; letter-spacing: -.02em; color: #fff; }
.tm-cap-role { font: italic 13px/1.2 var(--serif); color: #e6e6e6; }
.tm-lead { max-width: 52ch; margin: 0 0 28px; font-size: clamp(17px, 1.4vw, 20px); line-height: 1.6; color: #e6e6e6; }
.tm-quick { list-style: none; display: flex; flex-wrap: wrap; gap: 4px 24px; margin: 0 0 28px; padding: 0; }
.tm-quick:has(+ .tm-quick-social) { margin-bottom: 4px; }
.tm-quick a { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-size: 16px; text-decoration: none; }
.tm-skills { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; }
.tm-skills li { padding: 7px 14px; border: 1px solid rgba(255, 255, 255, .22); border-radius: 999px; color: #d6d6d6; font-size: 13px; }
/* Rows: what I do, selected work. "(01)" numbering as in AP's service list. */
.tm-rows { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.tm-row { display: grid; grid-template-columns: 64px minmax(0, 1fr) minmax(0, 1.4fr) auto; gap: 8px 24px; align-items: baseline; padding: 24px 0; border-bottom: 1px solid var(--line); }
.tm-row > div { grid-column: 2 / 4; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 4px 24px; }
.tm-row > div .tm-meta { grid-column: 1; grid-row: 2; }
.tm-row > div > p:last-child { grid-column: 2; grid-row: 1 / 3; }
.tm-row h3 { margin: 0; font-size: clamp(20px, 1.8vw, 26px); line-height: 1.15; letter-spacing: -.03em; }
.tm-row p { margin: 0; font-size: 16px; line-height: 1.55; }
.tm-row .tm-num { font: italic 14px/1 var(--serif); color: #9a9a9a; }
.tm-meta { font: italic 14px/1.3 var(--serif) !important; color: #bdbdbd; }
.tm-more { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; font-size: 15px; text-decoration: none; white-space: nowrap; }
/* Experience: logo, role and organisation, period. */
.tm-exps { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.tm-exp { display: grid; grid-template-columns: 48px minmax(0, 1fr) auto; gap: 4px 24px; align-items: start; padding: 24px 0; border-bottom: 1px solid var(--line); }
.tm-exp .tm-logo-org { width: 48px; height: 48px; margin: 0; border-radius: 50%; object-fit: cover; background: #fff; filter: none; opacity: 1; }
.tm-exp h3 { margin: 0 0 4px; font-size: clamp(20px, 1.8vw, 26px); line-height: 1.15; letter-spacing: -.03em; }
.tm-exp .tm-org { margin: 0 0 8px; font: italic 15px/1.3 var(--serif); color: #e0e0e0; text-transform: none; letter-spacing: 0; }
.tm-exp p { margin: 0; font-size: 16px; line-height: 1.55; }
.tm-exp .tm-period { margin: 4px 0 0; font: 14px/1.3 var(--sans); color: #bdbdbd; white-space: nowrap; letter-spacing: 0; }
.tm-block h3 { margin: 0 0 16px; font: italic 13px/1.3 var(--serif); letter-spacing: .2em; text-transform: uppercase; color: #e6e6e6; }
.tm-blocks { margin-top: 0 !important; }
.tm-sec-head { padding-bottom: 24px; }
.tm-gallery { margin-top: 0; }
@media (max-width: 900px) {
  .tm-about-grid { grid-template-columns: 1fr; }
  .tm-row { grid-template-columns: 44px minmax(0, 1fr); }
  .tm-row > div { grid-column: 2; grid-template-columns: 1fr; }
  .tm-row > div > p:last-child { grid-column: 1; grid-row: auto; }
  .tm-row > h3, .tm-row > p { grid-column: 2; }
  .tm-more { grid-column: 2; }
  .tm-exp { grid-template-columns: 40px minmax(0, 1fr); }
  .tm-exp .tm-logo-org { width: 40px; height: 40px; }
  .tm-exp .tm-logo-org { grid-row: 1 / span 2; }
  .tm-exp .tm-period { grid-column: 2; grid-row: 1; margin: 0 0 4px; }
  .tm-exp > div { grid-column: 2; grid-row: 2; }
}

/* ---- reveal on scroll ---------------------------------------------------------------- */
.js .tm-rise { opacity: 0; transform: translateY(44px); transition: opacity 1s var(--ease), transform 1s var(--ease); }
.js .tm-rise.in { opacity: 1; transform: none; }

/* ---- smaller screens ------------------------------------------------------------------ */
@media (max-width: 1100px) {
  .tm-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tm-fact:nth-child(2) { border-right: 0; }
  .tm-fact:nth-child(3) { padding-left: 0; }
  .tm-fact:nth-child(n+3) { border-top: 1px solid var(--line); }
}
@media (min-width: 641px) and (max-width: 1100px) {
  .tm-dock { bottom: 76px; }
  .tm-hero { padding-bottom: 190px; }
  .tm-foot { padding-bottom: 96px; }
}
@media (max-width: 900px) {
  .tm-about-grid, .tm-contact-in { grid-template-columns: 1fr; }
  .tm-card { max-width: 460px; }
  .tm-top ul { gap: 4px 22px; }
  .tm-top li:nth-child(2), .tm-top li:nth-child(3) { display: none; }
  .tm-foot-row ul { justify-content: flex-start; gap: 0 22px; }
}
@media (max-width: 640px) {
  .tm-top { padding-top: 14px; }
  .tm-hero { padding-bottom: clamp(56px, 9svh, 96px); }
  .tm-photo { height: min(90%, 200vw); }
  /* The name sits low on the chest: fade the photo out sooner, so a white shirt never swallows a letter. */
  .tm-photo img { -webkit-mask-image: linear-gradient(180deg, #000 52%, transparent 88%), linear-gradient(90deg, transparent 0%, #000 20%, #000 80%, transparent 100%);
    mask-image: linear-gradient(180deg, #000 52%, transparent 88%), linear-gradient(90deg, transparent 0%, #000 20%, #000 80%, transparent 100%); }
  .tm-quick-social { gap: 0 18px; }
  .tm-quick-social a { font-size: 15px; gap: 6px; }
  .tm-dock { left: 12px; right: 12px; bottom: 70px; transform: none; display: grid; grid-template-columns: auto 1fr auto; gap: 6px; }
  .tm-dock-btn { justify-content: center; min-height: 50px; padding: 0 16px; font-size: 14px; }
  .tm-dock-main { gap: 10px; padding-left: 4px; }
  .tm-dot { width: 42px; height: 42px; }
  .tm-item { grid-template-columns: 40px 1fr; }
  .tm-tabs [role="tablist"] { justify-content: flex-start; }
  .tm-tabs [role="tab"] { min-width: 132px; }
  .tm-facts { grid-template-columns: 1fr; }
  .tm-fact, .tm-fact + .tm-fact { padding-left: 0; border-right: 0; border-top: 1px solid var(--line); }
  .tm-fact:first-child { border-top: 0; }
  .tm-foot { padding-bottom: 150px; }
}
@media (max-width: 480px) {
  .tm-long { display: none; }
  .tm-short { display: inline; }
}
@media (max-width: 360px) {
  .tm-dock { left: 8px; right: 8px; gap: 4px; }
  .tm-dock-btn { padding: 0 12px; }
  .tm-dot { width: 36px; height: 36px; }
}
@media (max-width: 300px) {
  .tm-dock-btn { padding: 0 9px !important; font-size: 11px; }
}
/* Phones, small tablets and touch screens: no hover, so the person is always shown in the original colours
   of AP's photo, on black. */
@media (max-width: 768px), (hover: none) {
  .tm-hero { background: #000; }
  .tm-hero::before { display: none; }
  .tm-photo .tm-color { opacity: 1; }
}

/* ---- motion preferences ---------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .tm-name, .js .tm-photo .tm-bw { animation: none; }
  .js .tm-rise { opacity: 1; transform: none; transition: none; }
  .js .tm-manifesto .tm-w { color: #fff; }
  .tm-outline span { filter: none !important; transform: none !important; }
}
html.ap-motion-paused .tm-rise { opacity: 1; transform: none; }
@media (forced-colors: active) {
  .tm-outline span { color: CanvasText; -webkit-text-stroke: 0; }
  .tm-dot { forced-color-adjust: none; }
}

/* No floating bars on the profiles: AP's language/cookies/pause dock is hidden here; the language switch is in
   the menu, and "Cookie settings" and "Pause animations" are in the footer's legal links. */
body .ap-dock { display: none !important; }
.tm-linkbtn { display: inline-flex; align-items: center; min-height: 40px; padding: 0; border: 0; background: none; color: #e6e6e6; font: 12px/1 var(--sans); cursor: pointer; }
.tm-linkbtn:hover { color: var(--accent); }
.tm-linkbtn[aria-pressed="true"] { color: var(--accent); }
.tm-top .tm-lang a { padding: 12px 10px 0; margin-left: -10px; }
.tm-hero { padding-bottom: clamp(56px, 9vh, 110px) !important; }
.tm-foot { padding-bottom: 28px !important; }
@media (max-width: 900px) { .tm-top li.tm-lang { display: list-item !important; } }

/* Typography for the profiles: titles in Inter Display Bold, highlights in Instrument Serif Italic,
   text in Inter. */
body { font-optical-sizing: auto; }
h1, h2, h3, .tm-h2, .tm-cap-name, .tm-foot-h, .tm-contact-text h2, .tm-row h3, .tm-exp h3, .tm-block strong, .tm-form-h {
  font-family: var(--display) !important; font-weight: 700 !important; font-variation-settings: "opsz" 32; letter-spacing: -.035em !important;
}
.tm-block strong { letter-spacing: -.01em !important; }
.tm-eyebrow, .tm-block h3, .tm-cap-role, .tm-meta, .tm-exp .tm-org, .tm-num, .tm-cycle, .tm-period { font-family: var(--serif) !important; font-style: italic !important; font-weight: 400 !important; }
.tm-exp .tm-period { font-size: 15px !important; }

/* Phones held sideways: the screen is short, so the photo starts below the menu and the name stays on the chest. */
@media (orientation: landscape) and (max-height: 520px) {
  .tm-hero { min-height: max(100svh, 360px); padding-bottom: 28px; }
  .tm-photo { height: calc(100% - 72px); }
}

/* Phones: one photo only. The hero becomes AP's team card (the person on the card's gradient), and the card in
   "About" is hidden, so the same photo does not show twice in a row. */
.tm-hero-bg { display: none; }
@media (max-width: 768px) {
  .tm-hero-bg { display: block; position: absolute; z-index: -2; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center bottom; }
  .tm-hero-bg.tm-card-blue { filter: hue-rotate(190deg) saturate(1.15); }
  .tm-hero::after { content: ""; position: absolute; z-index: -1; left: 0; right: 0; bottom: 0; height: 24%; background: linear-gradient(180deg, transparent, #000 92%); pointer-events: none; }
  .tm-photo img { -webkit-mask-image: linear-gradient(180deg, #000 70%, transparent 100%); mask-image: linear-gradient(180deg, #000 70%, transparent 100%); }
  .tm-name { mix-blend-mode: normal; }
  .tm-about .tm-card { display: none; }
}

/* Business-card profile (Eduardo): contact is one email button, no form. */
.tm-contact-simple .tm-contact-in { grid-template-columns: 1fr; max-width: 760px; text-align: left; }
.tm-mail { display: inline-flex; align-items: center; gap: 12px; margin-top: 12px; min-height: 56px; padding: 0 26px; border: 1px solid rgba(255,255,255,.4); border-radius: 999px;
  color: #fff; font-size: clamp(16px, 2.2vw, 20px); text-decoration: none; transition: background .3s, color .3s, border-color .3s; max-width: 100%; }
.tm-mail span { overflow-wrap: anywhere; }
.tm-mail:hover, .tm-mail:focus-visible { background: var(--accent); border-color: var(--accent); color: #fff; }
