/* The Feast's gallery ring (dress-ring.js). --w, --h, --r, --stage and --pivot are measured: the
   photograph's size, the wheel's radius, the stage height and where the pivot sits above it. */

.ev-ring {
  position: relative;
  left: 50%;
  width: 100vw;
  margin: 26px 0 0 -50vw;
  overflow: clip; /* the rim runs off the screen without widening the page */
}
.ev-ring__stage {
  position: relative;
  height: var(--stage, 500px);
  overflow: clip;
  perspective: 1300px;
  perspective-origin: 50% 30%;
  cursor: grab;
  touch-action: pan-y; /* vertical scrolling stays with the page */
  user-select: none;
  -webkit-user-select: none;
}
.ev-ring__stage.is-turning { cursor: grabbing; }
/* The wheel is a point: the pivot. Everything hangs from it. */
.ev-ring__wheel { position: absolute; left: 50%; top: var(--pivot, 0); width: 0; height: 0; transform-style: preserve-3d; will-change: transform; }
.ev-ring__panel {
  position: absolute;
  left: 0;
  top: 0;
  isolation: isolate;
  overflow: hidden;
  width: var(--w, 240px);
  height: var(--h, 320px);
  margin: calc(var(--h, 320px) / -2) 0 0 calc(var(--w, 240px) / -2);
  /* no ground of its own: the cut-out outfits stand straight on the page */
  transform: rotate(var(--a, 0deg)) translateY(var(--r, 500px));
}
.ev-ring__img { display: block; width: 100%; height: 100%; object-fit: contain; pointer-events: none; }

.ev-ring__bar { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 14px; }
.ev-ring__count { min-width: 56px; font: 500 11px/1 "Archivo", system-ui, sans-serif; letter-spacing: .22em; text-align: center; color: var(--gl-gold-light); opacity: .85; }
.ev-ring__btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 32px;
  height: 32px;
  margin: 0;
  padding: 0;
  border: 1px solid rgba(216, 183, 106, .55);
  border-radius: 50%;
  background: rgba(11, 23, 16, .5);
  color: var(--gl-gold-light);
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  transition: background-color .3s ease, border-color .3s ease, scale .18s ease;
}
.ev-ring__btn svg { width: 15px; height: 15px; }
.ev-ring__btn::after { content: ""; position: absolute; inset: -7px; border-radius: 50%; } /* a 44px touch area */
.ev-ring__btn:hover { background: rgba(11, 23, 16, .75); border-color: var(--gl-gold); }
.ev-ring__btn:focus-visible { outline: 1px solid var(--gl-gold); outline-offset: 3px; }
.ev-ring__btn:active { scale: .95; }

@media (prefers-reduced-motion: reduce) {
  .ev-ring__btn { transition: none; }
  .ev-ring__btn:active { scale: none; }
}
