/* Experience upgrades (Nov 2026)
   1. Up close: a slab that catches the light as you move, with a magnifier
   2. Book-match maker: lay the stone out as a mirrored pair, four-way or long wall
   3. Quarry to home: real photos in the "Block to slab" story on the home page */

/* ---------- shared section ---------- */
.xp { position: relative; padding: clamp(64px, 8vw, 120px) var(--edge); border-top: 1px solid var(--line); }
.xp__head { max-width: 760px; margin: 0 auto clamp(30px, 4vw, 56px); text-align: center; }
.xp__head .eyebrow { margin-bottom: 18px; }
.xp__head h2 { margin: 0; }
.xp__lead { margin: 16px auto 0; max-width: 34em; color: var(--ivory2); font: 400 clamp(16px, 1.15vw, 18px)/1.7 var(--sans); }
.xp__grid { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, 1fr); gap: clamp(28px, 3.4vw, 56px); max-width: 1240px; margin: 0 auto; align-items: start; }
.xp__k { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin: 0 0 14px; }
.xp__k h3 { margin: 0; font: 500 clamp(22px, 1.8vw, 28px)/1.2 var(--disp); color: var(--ivory); }
.xp__k span { color: var(--gold); font: 500 11px/1 var(--sans); letter-spacing: .22em; text-transform: uppercase; white-space: nowrap; }
.xp__note { margin: 14px 0 0; color: var(--mute); font: 400 max(14px, .9em)/1.6 var(--sans); }

/* ---------- 1. up close ---------- */
.xp__slab { position: relative; aspect-ratio: var(--ar, 4 / 3); overflow: hidden; border: 1px solid var(--line); background: #0d0c0b center / cover no-repeat;
  transform: perspective(1400px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: transform .6s cubic-bezier(.2, .7, .2, 1);
  touch-action: pan-y; cursor: crosshair; -webkit-user-select: none; user-select: none; }
.xp__slab.is-live { transition: transform .12s linear; }
.xp__shine { position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(circle at var(--mx, 28%) var(--my, 30%), rgba(255, 255, 255, .5), rgba(255, 255, 255, .14) 16%, rgba(255, 255, 255, 0) 38%),
    linear-gradient(105deg, rgba(255, 255, 255, 0) calc(var(--mx, 28%) - 16%), rgba(255, 255, 255, .26) var(--mx, 28%), rgba(255, 255, 255, 0) calc(var(--mx, 28%) + 16%));
  mix-blend-mode: soft-light; }
.xp__slab::after { content: ''; position: absolute; inset: 0; pointer-events: none; box-shadow: inset 0 0 80px rgba(0, 0, 0, .35); }
.xp__lens { position: absolute; left: 0; top: 0; width: var(--lr2, 210px); height: var(--lr2, 210px); margin: calc(var(--lr2, 210px) / -2) 0 0 calc(var(--lr2, 210px) / -2);
  border-radius: 50%; pointer-events: none; background-repeat: no-repeat; background-color: #0d0c0b;
  border: 1px solid rgba(227, 198, 144, .9); box-shadow: 0 0 0 5px rgba(10, 9, 8, .35), 0 24px 60px rgba(0, 0, 0, .6);
  scale: 0; opacity: 0; transition: scale .28s cubic-bezier(.2, .7, .2, 1), opacity .2s; z-index: 2; }
.xp__lens::after { content: ''; position: absolute; inset: 0; border-radius: 50%; background: radial-gradient(circle at 35% 30%, rgba(255, 255, 255, .22), rgba(255, 255, 255, 0) 45%); }
.xp__slab.is-look .xp__lens { scale: 1; opacity: 1; }
.xp__hint { position: absolute; left: 14px; bottom: 12px; z-index: 1; padding: 8px 12px; background: rgba(10, 9, 8, .62); color: #efe8dc;
  font: 500 10.5px/1 var(--sans); letter-spacing: .18em; text-transform: uppercase; pointer-events: none; transition: opacity .4s; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.xp__slab.is-look .xp__hint { opacity: 0; }

/* ---------- 2. book-match maker ---------- */
.xp__wall { position: relative; display: grid; gap: 3px; aspect-ratio: 4 / 3; padding: 3px; background: #090807; border: 1px solid var(--line); overflow: hidden; }
.xp__wall[data-lay="pair"] { grid-template-columns: 1fr 1fr; }
.xp__wall[data-lay="quad"] { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; }
.xp__wall[data-lay="long"] { grid-template-columns: repeat(4, 1fr); }
.xp__wall[data-lay="pair"] .xp__t:nth-child(n+3) { display: none; }
.xp__t { background-repeat: no-repeat; background-color: #151311; transition: background-position .5s cubic-bezier(.2, .7, .2, 1); }
.xp__wall.is-drag .xp__t { transition: none; }
.xp__t--x { transform: scaleX(-1); }
.xp__t--y { transform: scaleY(-1); }
.xp__t--xy { transform: scale(-1, -1); }
.xp__wall::after { content: ''; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(120deg, rgba(255, 255, 255, .12), rgba(255, 255, 255, 0) 38%, rgba(255, 255, 255, 0) 70%, rgba(255, 255, 255, .06)); }
.xp__ctl { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; margin-top: 16px; }
.xp__seg { display: inline-flex; border: 1px solid var(--line); }
.xp__seg button { min-height: 42px; padding: 0 16px; border: 0; background: none; color: var(--ivory2); font: 500 11px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; cursor: pointer; transition: background .3s, color .3s; }
.xp__seg button + button { border-left: 1px solid var(--line); }
.xp__seg button[aria-pressed="true"] { background: var(--gold); color: #14120f; }
.xp__rng { flex: 1 1 200px; display: grid; gap: 8px; color: var(--mute); font: 500 10.5px/1 var(--sans); letter-spacing: .18em; text-transform: uppercase; }
.xp__rng input { width: 100%; height: 26px; margin: 0; accent-color: var(--gold); cursor: pointer; }
.xp__ask { display: inline-flex; align-items: center; gap: 10px; margin-top: 18px; color: var(--gold2, var(--gold)); font: 500 12px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; border-bottom: 1px solid currentColor; padding-bottom: 5px; }

@media (max-width: 900px) {
  .xp__grid { grid-template-columns: 1fr; }
  .xp__slab { transform: none; }
  .xp__lens { --lr2: 160px; }
}
@media (max-width: 520px) {
  .xp__k { flex-direction: column; align-items: flex-start; gap: 8px; }
  .xp__seg { width: 100%; }
  .xp__seg button { flex: 1; padding: 0 8px; }
}

/* ---------- 3. quarry to home: photos in the home page story ---------- */
.px.has-photos .px__svg { display: none; }
.pxp { position: relative; width: 100%; aspect-ratio: 800 / 520; max-height: calc(100svh - 190px); overflow: hidden; background: #0d0c0b; border: 1px solid var(--line); }
.pxp img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; scale: 1.12;
  transition: opacity 1s ease, scale 7s cubic-bezier(.2, .6, .2, 1); will-change: opacity, scale; }
.pxp img.is-on { opacity: 1; scale: 1; }
.pxp::after { content: ''; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(to top, rgba(10, 9, 8, .55), rgba(10, 9, 8, 0) 40%), radial-gradient(120% 100% at 50% 50%, rgba(0, 0, 0, 0) 60%, rgba(0, 0, 0, .35)); }
.pxp__cap { position: absolute; left: 18px; bottom: 16px; z-index: 1; display: flex; align-items: baseline; gap: 12px; color: #efe8dc; }
.pxp__cap b { color: #e3c690; font: 500 11px/1 var(--sans); letter-spacing: .22em; }
.pxp__cap span { font: 500 clamp(18px, 1.6vw, 24px)/1 var(--disp); }
@media (max-width: 900px) { .pxp { max-height: 46svh; } }

@media (prefers-reduced-motion: reduce) {
  .xp__slab, .xp__t, .pxp img { transition: none; }
  .pxp img { scale: 1; }
}
