/* How a project works · the marble run. Lays itself out by its own width (container queries):
   under 600px a column down the left, 600–999px a column with examples beside, 1000px+ one row. */
.ps { container-type: inline-size; position: relative; color: #2a1219; }
.ps-top { display: flex; flex-direction: column; gap: 18px; }
.ps-head { display: flex; flex-direction: column; gap: 14px; }
.ps-head h2 { font-size: clamp(40px, 9cqi, 68px); line-height: .98; }
.ps-head h2 i { color: #6b022b; }
.ps-lead { font-size: 17px; line-height: 1.5; color: #4a3a40; max-width: 560px; }
.ps-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.ps-chip { all: unset; box-sizing: border-box; cursor: pointer; display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px; border-radius: 999px; font-size: 15px; font-weight: 700; border: 1.5px solid #e1d3cc; background: #ffffff; color: #2a1219; transition: background-color .2s ease, color .2s ease, border-color .2s ease; }
.ps-chip:hover { border-color: #6b022b; }
.ps-chip.on { background: #2a1219; border-color: #2a1219; color: #fffef5; }
.ps-chip:focus-visible { outline: 3px solid #2a1219; outline-offset: 3px; }
.ps-hint { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: #7a6a70; }
.ps-hint img { width: 18px; height: 18px; }
.ps-steps { position: relative; display: grid; gap: 30px; margin-top: 36px; }
.ps-lane { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.ps-lane svg { position: absolute; left: 0; top: 0; overflow: visible; }
.ps-dash { fill: none; stroke: #f55747; stroke-width: 3; stroke-dasharray: 8 8; stroke-linecap: round; opacity: .5; }
.ps-trail { fill: none; stroke: #f55747; stroke-width: 6; stroke-linecap: round; transition: opacity .5s ease; }
.ps-ball { position: absolute; left: 0; top: 0; width: 38px; height: 38px; will-change: transform; filter: none; box-shadow: none; transition: opacity .5s ease; }
.ps-step { position: relative; z-index: 1; display: grid; grid-template-columns: 52px minmax(0, 1fr); column-gap: 18px; row-gap: 12px; align-items: start; align-content: start; cursor: pointer; border-radius: 20px; outline: none; -webkit-tap-highlight-color: transparent; }
.ps-step:focus-visible { outline: 3px solid #2a1219; outline-offset: 8px; }
.ps-txt { display: flex; flex-direction: column; gap: 8px; padding-top: 2px; }
.ps-txt h3 { font-size: 20px; font-weight: 700; }
.ps-txt p { font-size: 15px; line-height: 1.45; color: #5a4148; }
.ps-ex { grid-column: 2; border-radius: 18px; background: #ffffff; padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; transition: box-shadow .3s ease, transform .4s cubic-bezier(.3, 1.6, .5, 1); }
.ps-ex .k { font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: #6b022b; }
.ps-ex p { font-family: 'Instrument Serif', Georgia, serif; font-size: 21px; line-height: 1.2; }
.ps-step.is-on .ps-ex { box-shadow: 0 0 0 2px #f55747, 0 18px 30px -22px rgba(245, 87, 71, .7); transform: translateY(-3px); }
.ps-shape { position: relative; box-sizing: border-box; width: 52px; height: 52px; display: grid; place-items: center; font-weight: 700; font-size: 18px; transition: filter .3s ease; }
.ps-step.is-on .ps-shape { filter: drop-shadow(0 0 10px rgba(245, 87, 71, .55)); }
.ps-shape.hit { animation: ps-jelly .7s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes ps-jelly { 0% { transform: scale(1, 1); } 30% { transform: scale(1.28, .78); } 50% { transform: scale(.84, 1.16); } 70% { transform: scale(1.08, .94); } 100% { transform: scale(1, 1); } }
.ps-s1 { background: #f55747; color: #ffffff; border-radius: 50%; }
.ps-s2 { background: #e2fb84; color: #2a1219; clip-path: polygon(50% 0, 100% 100%, 0 100%); align-content: end; padding-bottom: 5px; box-sizing: border-box; }
.ps-s3 { background: #fbbdb7; color: #2a1219; clip-path: polygon(25% 4%, 75% 4%, 100% 50%, 75% 96%, 25% 96%, 0 50%); }
.ps-s4 { background: #6b022b; color: #fffef5; clip-path: polygon(50% 0, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%); padding-top: 6px; box-sizing: border-box; font-size: 15px; }
@container (min-width: 600px) {
  .ps-steps { gap: 36px; }
  .ps-step { grid-template-columns: 52px minmax(0, 1fr) minmax(0, 1fr); column-gap: 22px; }
  .ps-ex { grid-column: 3; }
}
@container (min-width: 1000px) {
  .ps-top { flex-direction: row; justify-content: space-between; align-items: flex-end; gap: 40px; }
  .ps-chips { flex: none; }
  .ps-steps { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 22px; margin-top: 52px; }
  .ps-step { grid-template-columns: minmax(0, 1fr); row-gap: 14px; }
  .ps-txt { min-height: 118px; }
  .ps-ex { grid-column: 1; }
}
@media (prefers-reduced-motion: reduce) { .ps-shape.hit { animation: none; } .ps-ex { transition: none; } }
