/* =========================================================
   /projects/ page (loaded after assets/css/styles.css)
   ========================================================= */
.page-projects{ --rail-w: 0px; }
.pj-main{ padding-left: 0; }
.pj-main > section, .pj-main > .pj-empty{ max-width: 1120px; margin: 0 auto; padding-left: 32px; padding-right: 32px; }

/* ---------- Header ---------- */
.pj-hero{ padding-top: calc(var(--topbar-h) + 44px); padding-bottom: 8px; }
.pj-back{
  display: inline-flex; align-items: center; gap: 6px; margin-bottom: 26px;
  font-size: 13.5px; font-weight: 500; color: var(--muted);
  transition: color .2s, gap .25s cubic-bezier(.3,1.4,.45,1);
}
.pj-back .icon{ width: 15px; height: 15px; }
.pj-back:hover{ color: var(--ink); gap: 9px; }
.pj-title{ font-family: var(--font-display); font-size: clamp(2rem, 5vw, 3.1rem); line-height: 1.08; letter-spacing: -0.025em; margin: 8px 0 14px; }
.pj-count{ font-size: .45em; font-weight: 500; color: var(--muted-2); letter-spacing: 0; vertical-align: .35em; margin-left: 4px; }

.pj-tools{ display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; margin-top: 30px; }
.pj-filters{ display: flex; flex-wrap: wrap; gap: 8px; }
.pj-n{ font-family: var(--font-mono); font-size: .82em; opacity: .55; margin-left: 2px; }
.filter-btn.is-on .pj-n{ opacity: .8; }
.pj-search{ position: relative; display: block; flex: 0 1 300px; min-width: 220px; }
.pj-search .icon{ position: absolute; left: 13px; top: 50%; width: 16px; height: 16px; transform: translateY(-50%); color: var(--muted-2); pointer-events: none; }
.pj-search input{
  width: 100%; height: 42px; padding: 0 14px 0 38px;
  border-radius: 12px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink);
  font: 400 15px/1 var(--font-body);
  transition: border-color .2s, box-shadow .2s;
}
.pj-search input::placeholder{ color: var(--muted-2); }
.pj-search input:focus{ outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-tint); }

/* ---------- Grid + cards ---------- */
.pj-grid{
  display: grid; grid-template-columns: repeat(auto-fill, minmax(310px, 1fr)); gap: 20px;
  margin-top: 30px; padding-bottom: 20px;
}
.pj-card{ padding: 14px 14px 20px; gap: 10px; position: relative; }
.pj-card[hidden]{ display: none; }
.pj-card > :not(.pj-preview){ margin-left: 8px; margin-right: 8px; }
.pj-card .project-title{ font-size: 1.12rem; }
.pj-card .project-title a{ color: inherit; }
.pj-card .project-title a::after{ content: ""; position: absolute; inset: 0; border-radius: inherit; } /* whole card opens */
.pj-card .project-link, .pj-preview{ position: relative; z-index: 1; }
.pj-footer{ display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.pj-footer .project-link{ padding-left: 12px; padding-right: 12px; }
.pj-details{ border-color: transparent; background: var(--accent-tint); color: var(--accent-ink); }
.pj-details span{ transition: transform .25s cubic-bezier(.3,1.4,.45,1); display: inline-block; }
.pj-card:hover .pj-details span{ transform: translateX(3px); }
.pj-more{ opacity: .75; }

.pj-preview{
  display: block; width: 100%; aspect-ratio: 16 / 8.2; padding: 38px 22px 14px; /* top room for badges */
  border: 1px solid var(--line); border-radius: calc(var(--radius) - 4px);
  background: var(--sky-tint); cursor: pointer; overflow: hidden;
  transition: border-color .2s;
}
.pj-card:hover .pj-preview{ border-color: var(--line-strong); }
.pj-preview:focus-visible{ outline: 2px solid var(--accent); outline-offset: 2px; }
.pj-badges{ position: absolute; top: 10px; left: 10px; display: flex; gap: 6px; flex-wrap: wrap; }
.pj-badge{
  padding: 3px 8px; border-radius: 999px; font: 600 10.5px/1.4 var(--font-mono); letter-spacing: .02em;
  background: var(--surface); color: var(--muted); border: 1px solid var(--line);
}
.pj-badge-featured{ color: #A9771A; }
:root[data-theme="dark"] .pj-badge-featured{ color: #F2D27A; }
.pj-badge-live{ color: #23875A; }
:root[data-theme="dark"] .pj-badge-live{ color: #8FD6A8; }
.pj-badge-new{ background: var(--accent); color: #fff; border-color: transparent; }
:root[data-theme="dark"] .pj-badge-new{ color: #0E1119; }
.pj-badge-wip{ color: #A15C07; }
:root[data-theme="dark"] .pj-badge-wip{ color: #F5B971; }

/* "dash" preview (Power BI project): KPI tiles pop in, the donut draws, bars grow */
.pv-dash .pv-kpi{ fill: var(--surface); stroke: var(--line-strong); stroke-width: 1; opacity: 0; transform: translateY(-4px); transform-box: fill-box; }
.pv-dash .pv-ring{ fill: none; stroke: var(--line-strong); stroke-width: 6; }
.pv-dash .pv-arc{ fill: none; stroke: var(--accent); stroke-width: 6; stroke-dasharray: 39 100; stroke-dashoffset: 39; transform: rotate(-90deg); transform-origin: 22px 36px; }
.pv-dash .pv-dbar{ fill: var(--accent-light); opacity: .75; transform: scaleY(0); transform-origin: bottom; transform-box: fill-box; }
.pv-dash .pv-dbar.hi{ fill: var(--accent); opacity: 1; }
.in .pv-dash .pv-kpi{ animation: pvPop .45s cubic-bezier(.3,1.4,.45,1) forwards; animation-delay: calc(var(--i) * 90ms); }
.in .pv-dash .pv-arc{ animation: pvDraw 1s ease-out .3s forwards; }
.in .pv-dash .pv-dbar{ animation: pvGrow .7s cubic-bezier(.3,1.3,.45,1) forwards; animation-delay: calc(var(--i) * 80ms); }

.pj-empty{ text-align: center; padding-top: 40px; padding-bottom: 40px; color: var(--muted); }
.pj-empty .btn{ margin-top: 14px; }

/* Filtering: cards glide (View Transitions) */
::view-transition-group(*){ animation-duration: .38s; animation-timing-function: cubic-bezier(.3,1.1,.45,1); }

/* ---------- Animated previews ----------
   Two phases per visual:
   1. Intro: plays once on load and ends on the finished picture.
   2. Idle: right after the intro, one small element keeps looping.
   Hovering a card restarts both from 0 (projects.js → replayPreview). */
.pv{ width: 100%; height: 100%; overflow: visible; }
@keyframes pvPop{ to{ opacity: 1; transform: none; } }
@keyframes pvDraw{ to{ stroke-dashoffset: 0; } }
@keyframes pvIn{ to{ opacity: 1; } }

/* Ask my AI — intro: question → answer → reply bubble. Idle: typing dots */
.pv-chat .pv-b{ fill: var(--surface); stroke: var(--line-strong); stroke-width: .8; opacity: 0; transform: translateY(5px); transform-box: fill-box; }
.pv-chat .pv-me{ fill: var(--accent); stroke: none; }
.pv-chat .pv-typing circle{ fill: var(--muted-2); opacity: 0; transform-box: fill-box; transform-origin: center; }
.in .pv-chat .pv-b1{ animation: pvPop .45s cubic-bezier(.3,1.4,.45,1) .1s forwards; }
.in .pv-chat .pv-b2{ animation: pvPop .45s cubic-bezier(.3,1.4,.45,1) .6s forwards; }
.in .pv-chat .pv-b3{ animation: pvPop .45s cubic-bezier(.3,1.4,.45,1) 1.1s forwards; }
.in .pv-chat .pv-typing circle{ animation: pvDot 1.2s ease-in-out 1.5s infinite; }
.in .pv-chat .pv-typing circle:nth-child(2){ animation-delay: 1.65s; }
.in .pv-chat .pv-typing circle:nth-child(3){ animation-delay: 1.8s; }
@keyframes pvDot{ 0%,60%,100%{ opacity: .4; transform: none; } 30%{ opacity: 1; transform: translateY(-2.2px); } }

.pv-axis{ stroke: var(--line-strong); stroke-width: 1; }
@keyframes pvGrow{ to{ transform: scaleY(1); } }

/* Readmission — intro: risk phrases highlight in the note, the needle swings
   into the red. Idle: the needle trembles, the red phrases pulse */
.pv-note{ fill: var(--surface); stroke: var(--line-strong); stroke-width: 1; }
.pv-ln{ fill: var(--line-strong); }
.pv-hl{ opacity: 0; transform: scaleX(0); transform-origin: left; transform-box: fill-box; }
.pv-hl-a{ fill: #F59E0B; } .pv-hl-r{ fill: #EF4444; }
.pv-link{ fill: none; stroke: var(--muted-2); stroke-width: 1.4; stroke-dasharray: 2 2; }
.pv-g{ fill: none; stroke-width: 5; opacity: .9; }
.pv-g-lo{ stroke: #22C55E; } .pv-g-md{ stroke: #F59E0B; } .pv-g-hi{ stroke: #EF4444; }
.pv-needle{ stroke: var(--ink); stroke-width: 2.2; stroke-linecap: round; transform-box: view-box; transform-origin: 94px 42px; transform: rotate(-90deg); }
.pv-hub{ fill: var(--ink); }
.in .pv-hl{ animation: pvMark .35s ease-out forwards; animation-delay: calc(.15s + var(--i) * .3s); }
.in .pv-hl-r{ animation: pvMark .35s ease-out forwards, pvFlag 2.4s ease-in-out infinite; animation-delay: calc(.15s + var(--i) * .3s), 2s; }
.in .pv-needle{ animation: pvSwing 1.1s cubic-bezier(.3,1.5,.5,1) 1.05s forwards, pvTremble 2.6s ease-in-out 2.2s infinite; }
@keyframes pvMark{ to{ opacity: .45; transform: none; } }
@keyframes pvFlag{ 0%,100%{ opacity: .45; transform: none; } 50%{ opacity: .7; transform: none; } }
@keyframes pvSwing{ to{ transform: rotate(52deg); } }
@keyframes pvTremble{ 0%,100%{ transform: rotate(52deg); } 50%{ transform: rotate(44deg); } }

/* NBA — intro: the shot's arc draws. Idle: the ball flies along it and drops through the net */
.pv-pole{ stroke: var(--line-strong); stroke-width: 2.4; }
.pv-board{ fill: var(--surface); stroke: var(--muted-2); stroke-width: 1.2; }
.pv-rim{ stroke: #E0773B; stroke-width: 2.4; stroke-linecap: round; }
.pv-net{ fill: none; stroke: var(--muted-2); stroke-width: .9; stroke-linejoin: round; }
.pv-shot{ fill: none; stroke: var(--accent-light); stroke-width: 1.6; stroke-dasharray: 100; stroke-dashoffset: 100; }
.pv-hball{ fill: #E0773B; stroke: #9A4A1E; stroke-width: .8; opacity: 0; }
.in .pv-shot{ animation: pvDraw 1s ease-out .1s forwards; }
.in .pv-hball{ animation: pvIn .3s ease .9s forwards; }

/* EV — intro: the battery's cells fill one by one and the growth line draws.
   Idle: the cells keep charging, the bolt flickers */
.pv-batt{ fill: var(--surface); stroke: var(--ink); stroke-width: 2; }
.pv-tip{ fill: var(--ink); }
.pv-cell{ fill: var(--accent); opacity: 0; transform: scaleX(.3); transform-origin: left; transform-box: fill-box; }
.pv-bolt{ fill: #F2C94C; stroke: var(--ink); stroke-width: 1.2; stroke-linejoin: round; opacity: 0; }
.pv-grow{ fill: none; stroke: var(--accent); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 100; stroke-dashoffset: 100; }
.pv-gdot{ fill: var(--accent); opacity: 0; }
.in .pv-cell{ animation: pvCharge .35s ease-out forwards, pvCells 2.4s ease-in-out infinite; animation-delay: calc(var(--i) * .22s), calc(1.4s + var(--i) * .3s); }
.in .pv-bolt{ animation: pvIn .3s ease 1s forwards, pvFlicker 2.4s ease-in-out 1.6s infinite; }
.in .pv-grow{ animation: pvDraw 1.3s ease-in-out .3s forwards; }
.in .pv-gdot{ animation: pvIn .3s ease 1.5s forwards; }
@keyframes pvCharge{ to{ opacity: 1; transform: none; } }
@keyframes pvCells{ 0%,100%{ opacity: 1; transform: none; } 50%{ opacity: .35; transform: none; } }
@keyframes pvFlicker{ 0%,100%{ opacity: 1; } 48%{ opacity: 1; } 52%{ opacity: .4; } 56%{ opacity: 1; } }

/* Sokoban — intro: dead end, then the route draws to the goal. Idle: goal glows, start pulses */
.pv-dots circle{ fill: var(--line-strong); }
.pv-dead{ fill: none; stroke: var(--muted-2); stroke-width: 2; stroke-dasharray: 3 3; opacity: 0; }
.pv-route{ fill: none; stroke: var(--accent); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 100; stroke-dashoffset: 100; }
.pv-goal{ fill: none; stroke: #E0A93B; stroke-width: 2; transform-box: fill-box; transform-origin: center; }
.pv-start{ fill: var(--accent); transform-box: fill-box; transform-origin: center; }
.in .pv-dead{ animation: pvDeadIn .3s ease .15s forwards; }
.in .pv-route{ animation: pvDraw 1.3s ease-in-out .45s forwards; }
.in .pv-goal{ animation: pvGlow 2.2s ease-in-out 1.75s infinite; }
.in .pv-start{ animation: pvPing 2.2s ease-out 1.75s infinite; }
@keyframes pvDeadIn{ to{ opacity: .7; } }
@keyframes pvGlow{ 0%,100%{ fill: rgba(224,169,59,0); transform: none; } 50%{ fill: rgba(224,169,59,.4); transform: scale(1.12); } }
@keyframes pvPing{ 0%,100%{ transform: scale(1); } 15%{ transform: scale(1.35); } 35%{ transform: scale(1); } }

/* Travel Buddy — intro: trip draws, pin drops. Idle: pin hovers, route dashes flow */
.pv-road{ fill: none; stroke: var(--line-strong); stroke-width: 6; stroke-linecap: round; }
.pv-trip{ fill: none; stroke: var(--accent); stroke-width: 2.4; stroke-linecap: round; stroke-dasharray: 100; stroke-dashoffset: 100; }
.pv-flow{ fill: none; stroke: var(--surface); stroke-width: 1.2; stroke-linecap: round; stroke-dasharray: 2 6; opacity: 0; }
.pv-from{ fill: var(--surface); stroke: var(--accent); stroke-width: 2; }
.pv-pin path{ fill: #D0473E; } .pv-pin circle{ fill: #fff; }
.pv-pin-shadow{ fill: rgba(0,0,0,.18); }
.pv-pin{ opacity: 0; }
.in .pv-trip{ animation: pvDraw 1.4s ease-in-out .15s forwards; }
.in .pv-pin{ animation: pvDrop .5s cubic-bezier(.3,1.5,.45,1) 1.5s forwards, pvHover 2.4s ease-in-out 2.1s infinite; }
.in .pv-flow{ animation: pvIn .4s ease 1.7s forwards, pvMarch 1.4s linear 1.7s infinite; }
@keyframes pvDrop{ from{ opacity: 0; transform: translateY(-9px); } to{ opacity: 1; transform: none; } }
@keyframes pvHover{ 0%,100%{ opacity: 1; transform: none; } 50%{ opacity: 1; transform: translateY(-2.5px); } }
@keyframes pvMarch{ to{ stroke-dashoffset: -16; } }

/* VR — intro: headset pops in, orbit appears. Idle: ball orbits, lenses glow */
.pv-orbit{ fill: none; stroke: var(--line-strong); stroke-width: 1.2; stroke-dasharray: 3 4; opacity: 0; }
.pv-headset{ fill: var(--ink); opacity: 0; transform: scale(.6); transform-box: fill-box; transform-origin: center; }
.pv-lens{ fill: var(--accent-light); opacity: 0; }
.pv-ball{ fill: var(--accent); opacity: 0; }
.in .pv-headset{ animation: pvPop .5s cubic-bezier(.3,1.5,.45,1) .1s forwards; }
.in .pv-lens{ animation: pvIn .25s ease .55s forwards, pvLens 2.4s ease-in-out 1.2s infinite; }
.in .pv-orbit{ animation: pvIn .5s ease .7s forwards, pvDash 6s linear 1.2s infinite; }
.in .pv-ball{ animation: pvIn .4s ease 1s forwards; }
@keyframes pvLens{ 0%,100%{ fill: var(--accent-light); opacity: 1; } 50%{ fill: var(--accent); opacity: 1; } }
@keyframes pvDash{ 0%{ opacity: 1; stroke-dashoffset: 0; } 100%{ opacity: 1; stroke-dashoffset: -42; } }

/* Portfolio — intro: pipe fills, stages light up in turn. Idle: a data packet travels the pipe */
.pv-pipe-line{ stroke: var(--line-strong); stroke-width: 3; stroke-linecap: round; }
.pv-pipe-fill{ stroke: var(--accent); stroke-width: 3; stroke-linecap: round; stroke-dasharray: 100; stroke-dashoffset: 100; }
.pv-stage{ fill: var(--surface); stroke: var(--line-strong); stroke-width: 2; transform-box: fill-box; transform-origin: center; }
.pv-packet{ fill: #F2D27A; opacity: 0; }
.in .pv-pipe-fill{ animation: pvDraw 1.6s ease-in-out .15s forwards; }
.in .pv-stage{ animation: pvStage .4s ease forwards; animation-delay: calc(.15s + var(--i) * .36s); }
.in .pv-packet{ animation: pvIn .3s ease 2s forwards; }
@keyframes pvStage{ 50%{ transform: scale(1.3); } to{ fill: var(--accent); stroke: var(--accent); transform: none; } }

/* ---------- CTA ---------- */
.pj-cta{ text-align: center; padding-top: 70px; padding-bottom: 70px; }
.pj-cta h2{ font-size: clamp(1.4rem, 3vw, 1.9rem); }
.pj-cta p{ color: var(--muted); margin: 10px auto 22px; max-width: 520px; }
.pj-cta-row{ display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.page-projects .footer{ max-width: 1120px; margin: 0 auto; padding-left: 32px; padding-right: 32px; }

/* ---------- Case-study panel ---------- */
body.pj-locked{ overflow: hidden; }
.pj-scrim{
  position: fixed; inset: 0; z-index: 110; background: rgba(14,17,25,.38);
  backdrop-filter: blur(3px); opacity: 0; transition: opacity .3s ease;
}
.pj-scrim.open{ opacity: 1; }
.pj-panel{
  position: fixed; z-index: 111; top: 10px; right: 10px; bottom: 10px;
  width: min(620px, calc(100vw - 20px));
  display: flex; flex-direction: column;
  background: var(--surface); color: var(--ink);
  border: 1px solid var(--line); border-radius: 22px;
  box-shadow: 0 30px 70px rgba(14,17,25,.28);
  transform: translateX(calc(100% + 24px)); transition: transform .42s cubic-bezier(.3,1.1,.4,1);
  overflow: hidden;
}
.pj-panel.open{ transform: none; }
.pj-panel-bar{ position: absolute; top: 12px; right: 12px; z-index: 2; }
.pj-panel-close{
  width: 38px; height: 38px; display: grid; place-items: center; border-radius: 12px;
  border: 1px solid var(--line); background: var(--surface); color: var(--muted); cursor: pointer;
  transition: color .2s, border-color .2s, transform .25s cubic-bezier(.3,1.4,.45,1);
}
.pj-panel-close:hover{ color: var(--ink); border-color: var(--line-strong); transform: rotate(90deg); }
.pj-panel-close svg{ width: 17px; height: 17px; }
.pj-panel-body{ overflow-y: auto; overscroll-behavior: contain; padding: 30px 32px 34px; flex: 1; }
.pj-panel-body > *{ opacity: 0; transform: translateY(8px); }
.pj-panel-body.in > *{ animation: pvPop .45s cubic-bezier(.3,1.2,.45,1) forwards; }
.pj-panel-body.in > :nth-child(2){ animation-delay: .04s; } .pj-panel-body.in > :nth-child(3){ animation-delay: .08s; }
.pj-panel-body.in > :nth-child(4){ animation-delay: .12s; } .pj-panel-body.in > :nth-child(5){ animation-delay: .16s; }
.pj-panel-body.in > :nth-child(n+6){ animation-delay: .2s; }
.pj-panel-title{ font-family: var(--font-display); font-size: clamp(1.5rem, 3.4vw, 2rem); line-height: 1.15; letter-spacing: -0.02em; margin: 6px 50px 10px 0; }
.pj-panel-lede{ color: var(--muted); font-size: 1rem; line-height: 1.6; }
.pj-badges-inline{ position: static; margin-top: 14px; }
.pj-actions{ display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.pj-hero-visual{ margin-top: 24px; aspect-ratio: 16 / 7; padding: 22px 28px; border-radius: 16px; background: var(--sky-tint); border: 1px solid var(--line); }
.pj-hero-visual .pv{ display: block; }
.pj-panel-body.in .pj-hero-visual{ --in: 1; }
.pj-panel-body.in .pj-hero-visual .pv{ animation: none; }
.pj-shots{ margin-top: 24px; display: grid; gap: 12px; }
.pj-shots figure{ margin: 0; }
.pj-shots img{ width: 100%; height: auto; display: block; border-radius: 14px; border: 1px solid var(--line); background: var(--sky-tint); }
.pj-shots figcaption{ margin-top: 6px; font-size: 12px; color: var(--muted-2); }
.pj-stats{ display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.pj-stats li{
  flex: 1 1 120px; padding: 12px 14px; border-radius: 14px; background: var(--sky-tint); border: 1px solid var(--line);
  font-family: var(--font-mono); font-size: 11.5px; color: var(--muted);
}
.pj-stats strong{ display: block; font-family: var(--font-display); font-size: 1.35rem; color: var(--ink); margin-bottom: 2px; }
.pj-panel-body section{ margin-top: 26px; }
.pj-panel-body h3{ font-family: var(--font-mono); font-size: 11.5px; font-weight: 500; text-transform: uppercase; letter-spacing: .07em; color: var(--accent); margin-bottom: 8px; }
.pj-panel-body section p{ line-height: 1.65; }
.pj-panel-body section ul{ display: grid; gap: 8px; }
.pj-panel-body section li{ position: relative; padding-left: 18px; line-height: 1.6; }
.pj-panel-body section li::before{ content: ""; position: absolute; left: 2px; top: .65em; width: 6px; height: 6px; border-radius: 2px; background: var(--accent-light); }
.pj-nav{ display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 34px; padding-top: 20px; border-top: 1px solid var(--line); }
.pj-nav a{ display: flex; flex-direction: column; gap: 3px; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--line); font-weight: 600; font-size: 14px; line-height: 1.35; transition: border-color .2s, background .2s; }
.pj-nav a span{ font: 500 11px/1 var(--font-mono); color: var(--muted-2); text-transform: uppercase; letter-spacing: .05em; }
.pj-nav a:hover{ border-color: var(--accent); background: var(--accent-tint); }
.pj-nav-next{ text-align: right; align-items: flex-end; }

/* The panel's own preview animates once it is in */
.pj-hero-visual .pv *{ animation-play-state: running; }

/* ---------- Small screens ---------- */
@media (max-width: 640px){
  .pj-main > section, .pj-main > .pj-empty, .page-projects .footer{ padding-left: 16px; padding-right: 16px; }
  .pj-hero{ padding-top: calc(var(--topbar-h) + 26px); }
  .pj-search{ flex: 1 1 100%; }
  .pj-grid{ grid-template-columns: 1fr; }
  .pj-panel{ top: auto; left: 0; right: 0; bottom: 0; width: 100%; height: 92dvh; border-radius: 22px 22px 0 0; transform: translateY(100%); }
  .pj-panel-body{ padding: 26px 18px 30px; }
  .pj-nav{ grid-template-columns: 1fr; }
  .pj-nav-next{ text-align: left; align-items: flex-start; }
}
@media (prefers-reduced-motion: reduce){
  .pj-panel, .pj-scrim{ transition: none; }
  .pj-panel-body > *, .pv *{ animation: none !important; opacity: 1 !important; transform: none !important; stroke-dashoffset: 0 !important; }
  ::view-transition-group(*){ animation: none; }
}

/* While a case study is open, the floating mic and AI button step aside */
body.pj-locked .mic-wrap, body.pj-locked .ask-fab{ opacity: 0; pointer-events: none; transform: scale(.85); }
.mic-wrap{ transition: opacity .2s ease, transform .25s cubic-bezier(.3,1.4,.45,1); }
