.folio-projects { padding-block: clamp(48px, 6vw, 80px) clamp(58px, 7vw, 96px); background: #f2f5f8; }
.gallery-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: clamp(22px, 3.1vw, 38px);
}
.gallery-heading h2 {
  font-size: clamp(2.3rem, 5.25vw, 4.55rem);
  font-weight: 675;
  letter-spacing: -.075em;
  line-height: 1.06;
}
.gallery-controls { display: flex; flex: none; align-items: center; gap: 8px; padding-bottom: 2px; }
.gallery-controls .position-count { padding-inline: 0 6px; color: #56677c; font-variant-numeric: tabular-nums; }
.gallery-step {
  display: grid;
  place-items: center;
  width: 45px;
  height: 45px;
  padding: 0;
  color: #2b4c78;
  border: 0;
  border-radius: 50%;
  background: #e0e7ee;
  cursor: pointer;
}
.gallery-step:not(:disabled):hover { background: #d5e1f0; color: #173f9e; }
.gallery-step:disabled { opacity: .48; cursor: default; }
.gallery-step::before {
  width: 8px;
  height: 8px;
  transform: translateX(-2px) rotate(-45deg);
  border-right: 1.6px solid currentColor;
  border-bottom: 1.6px solid currentColor;
  content: "";
}
.gallery-prev::before { transform: translateX(2px) rotate(135deg); }

.folio-projects .showcase[data-enhanced] { display: block; }
.folio-projects .project-viewport { border-radius: 14px; }
.folio-projects .project-track { align-items: flex-start; gap: clamp(12px, 2.1vw, 30px); }
.folio-projects .project-sheet { padding: 0; border: 0; }
.project-stage {
  position: relative;
  display: grid;
  align-items: center;
  min-height: clamp(450px, 43vw, 572px);
  clip-path: inset(0 round 14px);
  isolation: isolate;
  background: #e3eaf1;
}
.project-stage > header {
  position: relative;
  z-index: 2;
  max-width: 44%;
  padding: 30px 0 30px clamp(26px, 5vw, 71px);
  pointer-events: none;
}
.folio-projects .project-stage h3 {
  margin: 0;
  color: #243851;
  font: 655 clamp(2.45rem, 5.25vw, 5rem)/1.02 var(--display);
  letter-spacing: -.068em;
  overflow-wrap: normal;
  text-wrap: pretty;
}
.folio-projects .case-summary {
  margin-top: clamp(12px, 1.7vw, 21px);
  max-width: 19em;
  color: #41556d;
  font-size: clamp(1rem, 1.51vw, 1.23rem);
  line-height: 1.55;
  text-wrap: pretty;
}
.project-art {
  position: absolute;
  inset: 0 0 0 33%;
  margin: 0;
  transform: translate3d(var(--project-offset, 0px), 0, 0);
  z-index: 1;
  pointer-events: none;
}
.project-art figcaption {
  position: absolute;
  right: clamp(10px, 2vw, 23px);
  bottom: clamp(9px, 1.8vw, 20px);
  padding: 3px 8px;
  color: #455775;
  border-radius: 4px;
  background: #f8fafce6;
  font-size: .8rem;
  line-height: 1.4;
}

.stage-coach { background: #d6d9db; }
.coach-art { inset-inline-start: 25%; }
.coach-art picture, .coach-art img { display: block; width: 100%; height: 100%; }
.coach-art img { object-fit: cover; object-position: 70% center; }
.coach-art::after {
  position: absolute;
  inset: 0 64% 0 0;
  background: linear-gradient(90deg, #d6d9db, #d6d9db00);
  content: "";
}
.coach-art figcaption { z-index: 1; }

.stage-console { background: #dde7f0; }
.console-art { perspective: 1100px; }
.console-window {
  position: absolute;
  top: 14%;
  left: 12%;
  display: grid;
  grid-template-rows: auto 1fr auto;
  align-items: center;
  width: min(76%, 568px);
  height: 66%;
  padding: clamp(13px, 2.5vw, 33px);
  transform: rotateY(-14deg) rotateX(5deg) rotateZ(-6deg);
  border: 1px solid #adbbd1;
  border-radius: 12px;
  color: #2d4364;
  background: #f8fafc;
  box-shadow: 10px 9px 0 #b4c4d3, 28px 33px 55px #354d7e27;
}
.console-top { display: flex; gap: 5px; align-self: start; }
.console-top i { width: 6px; height: 6px; border-radius: 50%; background: #abbacf; }
.console-command { display: grid; align-content: center; gap: 5px; }
.console-command small { color: #60728c; font-size: .84rem; font-weight: 570; }
.console-command b { font: 665 clamp(1.25rem,2.75vw,2.75rem)/1.05 var(--display); letter-spacing: -.049em; }
.console-command code { color: #345b97; font: .87rem var(--mono); }
.console-wave { display: flex; align-items: end; gap: clamp(4px, .65vw, 8px); height: 24px; }
.console-wave i { width: 7px; height: 32%; border-radius: 2px; background: #6383b6; }
.console-wave i:nth-child(3n) { height: 66%; }
.console-wave i:nth-child(4n) { height: 91%; }
.console-wave i:nth-child(5n) { height: 46%; }
.console-proof {
  position: absolute;
  top: 57%;
  left: 39%;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 8px clamp(8px, 1.3vw, 15px);
  min-width: min(320px, 56%);
  padding: clamp(10px, 1.75vw, 21px);
  transform: rotateZ(-3deg);
  border: 1px solid #bbc9d9;
  border-radius: 9px;
  color: #324963;
  background: #ffffff;
  box-shadow: 3px 8px 0 #c5d3e1, 8px 18px 22px #3e57742b;
  font-size: clamp(.87rem, 1.35vw, 1.1rem);
  font-weight: 660;
}
.console-proof small { display: block; color: #5b6e84; font: 540 .82rem var(--display); }
.console-proof code { color: #375c95; font: .79rem var(--mono); white-space: nowrap; }
.console-led { width: 9px; height: 9px; border-radius: 50%; background: #315da4; box-shadow: 0 0 0 5px #e5ecf7; }

.stage-shipping { background: #e2e9ef; }
.shipping-art { perspective: 1000px; }
.shipping-pedestal {
  position: absolute;
  top: 59%;
  left: 14%;
  width: 72%;
  height: 20%;
  transform: rotateX(48deg) rotateZ(-11deg);
  border-radius: 8px;
  background: #cad6e2;
  box-shadow: 8px 10px 0 #b7c7d6, 14px 31px 27px #67809626;
}
.shipping-box {
  position: absolute;
  top: 25%;
  left: 23%;
  width: 52%;
  height: 43%;
  transform: skewY(-8deg) rotate(-2deg);
  border-radius: 6px 2px 3px 5px;
  background: #edf2f6;
  box-shadow: inset 0 0 0 1px #bdcbd7, 19px 21px 33px #4f65803d;
}
.shipping-box::before {
  position: absolute;
  inset: auto -4.8% 100% auto;
  width: 100%;
  height: 12%;
  transform: skewX(-52deg);
  border-radius: 4px 5px 0 0;
  background: #f6f8fa;
  content: "";
}
.shipping-box::after {
  position: absolute;
  inset: -6% auto auto 100%;
  width: 10%;
  height: 100%;
  transform: skewY(-43deg);
  border-radius: 0 3px 4px 0;
  background: #9eafc3;
  content: "";
}
.shipping-seal { position: absolute; top: 0; left: 26%; width: 17%; height: 100%; background: #c7d6e8; }
.shipping-label {
  position: absolute;
  display: grid;
  padding: clamp(6px,1.5vw,15px);
  top: 29%;
  left: 45%;
  width: 41%;
  min-height: 41%;
  align-content: center;
  gap: 5px;
  border-radius: 3px;
  color: #33557f;
  background: #fcfdfe;
  font-size: clamp(.79rem,1.5vw,1.02rem);
}
.shipping-label i {
  width: 90%;
  height: clamp(11px,2.6vw,24px);
  background: repeating-linear-gradient(90deg,#6f85a2 0 2px,transparent 2px 4px,#6f85a2 4px 5px,transparent 5px 7px);
}
.shipping-state {
  position: absolute;
  bottom: 9%;
  left: 10%;
  right: 9%;
  display: flex;
  justify-content: center;
  gap: clamp(7px,1vw,13px);
}
.shipping-state span {
  min-width: 66px;
  padding: 5px 9px;
  border-radius: 5px;
  color: #425e7b;
  background: #f2f6fa;
  font-size: .87rem;
  font-weight: 600;
  text-align: center;
}
.shipping-state span:last-child { color: white; background: #3e6096; }

.stage-diary { background: #e7eef3; }
.project-phone {
  position: absolute;
  overflow: hidden;
  border: 5px solid #cbd7e3;
  border-radius: clamp(16px,2.5vw,27px);
  background: #fdfefe;
  box-shadow: 5px 8px 0 #a9bbcf, 10px 26px 34px #4b658030;
}
.diary-phone {
  top: 13%;
  left: 22%;
  display: flex;
  flex-direction: column;
  align-items: start;
  gap: clamp(6px,1.25vw,15px);
  width: clamp(132px, 17vw, 220px);
  min-height: 69%;
  padding: clamp(10px,1.7vw,23px);
  transform: rotate(-8deg);
}
.diary-phone > i { align-self: center; width: 34%; height: 4px; margin: 1px 0 3px; border-radius: 4px; background: #a1b2c7; }
.diary-phone strong { color: #385377; font-size: clamp(.98rem,1.65vw,1.38rem); }
.diary-row {
  display: flex;
  align-items: center;
  gap: 7px;
  width: 100%;
  min-height: clamp(27px,4.1vw,54px);
  padding-inline: 7px;
  border-radius: 5px;
  color: #4c637f;
  background: #eaf0f6;
  font-size: clamp(.75rem,1.2vw,.99rem);
  font-weight: 560;
}
.diary-row > i { width: 8px; height: 8px; border-radius: 3px; background: #7e9abe; }
.diary-row:nth-of-type(2) > i { background: #9baec4; }
.diary-row:nth-of-type(3) > i { background: #4c76ab; }
.diary-proof {
  position: absolute;
  top: 54%;
  left: 46%;
  display: flex;
  align-items: center;
  gap: clamp(7px,1.25vw,15px);
  padding: clamp(9px,1.75vw,22px);
  transform: rotate(-4deg);
  border: 1px solid #b8cadb;
  border-radius: 7px;
  color: #335780;
  background: #fafcfe;
  box-shadow: 5px 12px 19px #3c5d7e26;
  font-size: clamp(.84rem,1.42vw,1.1rem);
  font-weight: 660;
  white-space: nowrap;
}
.diary-proof i { width: 14px; height: 14px; border-radius: 4px; background: #6489b8; }
.diary-proof small { display: block; color: #60748c; font-size: .79rem; font-weight: 490; }

.stage-linger-gallery { background: #dde7f1; }
.linger-gallery-art .project-phone { aspect-ratio: 390 / 844; }
.linger-gallery-art img { display: block; width: 100%; height: 100%; object-fit: cover; }
.linger-gallery-main { top: 10%; left: 20%; width: clamp(121px,19vw,216px); transform: rotate(-8deg); }
.linger-gallery-side { top: 14%; left: 49%; width: clamp(116px,17vw,198px); transform: rotate(9deg); }

.stage-delivery { background: #e2e8ef; }
.delivery-art { perspective: 1000px; }
.delivery-pane {
  position: absolute;
  display: grid;
  align-content: center;
  gap: 5px;
  width: 46%;
  height: 51%;
  padding: clamp(14px,2.5vw,32px);
  border: 1px solid #b1c3d5;
  border-radius: 11px;
  color: #435d80;
  background: #f2f6fa;
  box-shadow: 10px 10px 0 #b4c4d5, 13px 23px 35px #3a587b26;
}
.delivery-pane strong { font-size: clamp(1.01rem,2.15vw,1.82rem); line-height: 1.22; }
.delivery-pane span { color: #506782; font-size: clamp(.78rem,1.18vw,1.02rem); }
.delivery-pane-back { top: 13%; left: 15%; transform: rotateY(-16deg) rotateX(5deg) rotateZ(-10deg); background: #f7fafd; }
.delivery-pane-front { top: 36%; left: 44%; transform: rotateY(-18deg) rotateX(5deg) rotateZ(4deg); background: #c6d7e8; }
.delivery-mark { position: relative; width: clamp(36px,5vw,62px); height: clamp(27px,3.8vw,46px); margin-bottom: clamp(3px,1vw,12px); background: #7694ba; border-radius: 3px; }
.delivery-mark i { position: absolute; display: block; }
.delivery-mark i:first-child { inset: 0 50% 0 34%; background: #b3c6de; }
.delivery-mark i:last-child { right: 4px; bottom: 5px; width: 28%; height: 21%; border-radius: 1px; background: #e5eff8; }
.delivery-mark-open { background: #5677a2; }
.delivery-mark-open i:first-child { background: #8da9c9; }

.folio-projects .project-notes { margin: 0; padding: 8px 3px 12px; border: 0; }
.folio-projects .project-notes summary { width: fit-content; }
.folio-projects .project-notes[open] { padding-inline: clamp(12px,2vw,24px); background: #e8edf3; border-radius: 0 0 10px 10px; }
.folio-projects .project-notes :is(.case-flow li, .case-pair > div) { border-top: 0; padding-top: 2px; }
.folio-projects .project-notes :is(.case-flow, .case-pair) { margin: 2px 0 8px; }
.folio-projects .project-notes .case-flow { padding-inline-start: 1.3em; }
.folio-projects .project-notes .repository { margin: 3px 0 13px; }
.folio-projects .project-notes .case-link { margin: 5px 14px 0 0; }

.gallery-tray { margin-top: clamp(17px,3vw,32px); }
.folio-projects .project-pickers {
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 5px;
  overflow-x: auto;
  scrollbar-width: none;
}
.folio-projects .project-pickers::-webkit-scrollbar { display: none; }
.folio-projects .project-pickers button {
  flex: 0 0 auto;
  min-height: 45px;
  padding: 8px 15px;
  border: 0;
  border-radius: 24px;
  color: #405774;
  background: transparent;
  font: 570 clamp(.87rem,1.23vw,.98rem)/1.25 var(--display);
  white-space: nowrap;
}
.folio-projects .project-pickers button[aria-pressed="true"] { color: #fff; background: #325486; box-shadow: none; }
.folio-projects .project-pickers button[aria-pressed="false"]:hover { background: #e2e9f0; }

@media (prefers-reduced-motion: no-preference) {
  .gallery-step { transition: background-color 180ms, transform 190ms var(--ease); }
  .gallery-step:active:not(:disabled) { transform: scale(.94); }
  .folio-projects [data-enhanced] .project-track { transition: height 210ms var(--ease); }
  .folio-projects .is-dragging .project-track { transition-duration: 0ms; }
}

@media (max-width: 930px) {
  .folio-projects .project-pickers { justify-content: start; }
}
@media (max-width: 700px) {
  .project-stage { min-height: clamp(393px, 92vw, 500px); align-items: start; }
  .project-stage > header { max-width: 100%; padding: 26px 21px 0; }
  .folio-projects .project-stage h3 { font-size: clamp(2.04rem,8.3vw,3.72rem); }
  .folio-projects .case-summary { margin-top: 8px; max-width: 26em; }
  .project-art { inset: 113px 0 0; }
  .coach-art { inset: 112px 0 0; }
  .coach-art::after { display: none; }
  .coach-art img { object-position: 70% center; }
  .console-window { top: 10%; left: 13%; width: 71%; height: 63%; transform: rotateY(-13deg) rotateZ(-6deg); }
  .console-proof { left: 34%; min-width: 55%; }
  .shipping-box { top: 22%; }
  .shipping-state { bottom: 13%; }
  .diary-phone { top: 7%; }
  .linger-gallery-main { top: 4%; }
  .linger-gallery-side { top: 11%; }
  .gallery-controls { gap: 6px; }
  .gallery-step { width: 44px; height: 44px; }
  .folio-projects .project-pickers button { padding-inline: 12px; }
}
@media (max-width: 370px) {
  .project-stage > header { padding-inline: 17px; }
  .folio-projects .case-summary { font-size: .96rem; }
  .console-proof { left: 31%; gap: 6px; }
  .shipping-state span { min-width: 56px; }
  .diary-phone { left: 18%; }
  .diary-proof { left: 42%; }
  .linger-gallery-main { left: 16%; }
  .linger-gallery-side { left: 50%; }
}
