/* Brody shares the page with the work. Only the character and his controls receive input. */
.rt-wander {
  --figure-width: clamp(70px, 6.6vw, 90px);
  --figure-height: calc(var(--figure-width) * 1.5);
  position: fixed;
  inset: 0;
  z-index: 2147483000;
  isolation: isolate;
  overflow: hidden;
  pointer-events: none;
  color: #23271c;
  font-family: Arial, sans-serif;
}
.rt-wander[hidden], .rt-wander [hidden] { display: none !important; }
.rt-wander[data-party-held] { opacity:0; }

.rt-wander-pack {
  position: absolute;
  top: 0;
  left: 0;
  width: var(--figure-width);
  height: var(--figure-height);
  transform: translate3d(0, 0, 0);
  pointer-events: none;
}
.rt-wander-actor {
  appearance: none;
  display: block;
  position: relative;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 42% 42% 20% 20%;
  background: transparent;
  line-height: 0;
  color: inherit;
  cursor: grab;
  pointer-events: auto;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent;
}
.rt-wander-actor::before {
  content: '';
  position: absolute;
  left: 20%;
  bottom: 0;
  width: 60%;
  height: 5%;
  border-radius: 50%;
  background: radial-gradient(ellipse, #231e1682, transparent 70%);
  pointer-events: none;
}
.rt-wander-actor:is([data-mode="air"], [data-mode="held"])::before { opacity: 0; }
.rt-wander-actor:active, .rt-wander-actor[data-mode="held"] { cursor: grabbing; }
.rt-wander-art {
  display: block;
  position: absolute;
  inset: 0;
  transform-origin: 50% 53%;
  filter: drop-shadow(0 1px 1px #ebe3cc66) drop-shadow(0 2px 2px #1d1c183d);
  pointer-events: none;
}
.rt-wander-art img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
  -webkit-user-drag: none;
}
.rt-wander-body, .rt-wander-poses {
  position: absolute;
  display: block;
  inset: 0;
  pointer-events: none;
}
.rt-wander-body { transform-origin: 50% 96%; }
.rt-wander-body:is([data-reaction="flip"],[data-reaction="sore"]) { transform-origin: 50% 50%; }
.rt-wander-tape {
  position: absolute;
  display: none;
  left: 69%;
  top: 43.75%;
  width: 0;
  height: clamp(3px,.32vw,4px);
  overflow: hidden;
  border-radius: 1px;
  background-color: #efd276;
  background-image: repeating-linear-gradient(90deg,transparent 0 4px,#5b4936 4px 5px);
  background-size: 100% 55%;
  background-repeat: no-repeat;
  box-shadow: inset 0 -1px #9b7948;
}
.rt-wander-body[data-reaction="measure"] .rt-wander-tape { display: block; }
.rt-wander-tape::after {
  content: '';
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: #5c605b;
}
.rt-wander :is(button, a):focus-visible,
.rt-wander .rt-wander-actor[data-focus-input="keyboard"]:focus {
  outline: 2px solid #887139;
  outline-offset: 2px;
  box-shadow: 0 0 0 3px #fff9e9;
}

/* Safari may apply :focus-visible when the drag target takes focus on a tap. */
.rt-wander .rt-wander-actor[data-focus-input="pointer"] {
  outline: none;
  box-shadow: none;
}

@media (max-width: 640px) {
  .rt-wander { --figure-width: 62px; }
}
/* The dock keeps actions off the character and above the mobile call bar. */
.rt-play-dock {
  position:fixed; z-index:2147482999; right:max(12px,env(safe-area-inset-right));
  bottom:max(14px,env(safe-area-inset-bottom)); pointer-events:none;
  display:grid; justify-items:end; gap:6px; max-width:calc(100vw - 24px);
  color:#ece8db; font:13px/1.25 Arial,sans-serif;
}
.rt-play-dock[hidden], .rt-play-dock [hidden] {display:none !important}
.rt-play-dock button {appearance:none;cursor:pointer;pointer-events:auto;color:inherit;font:inherit}
.rt-play-dock svg {width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.35;stroke-linecap:round;stroke-linejoin:round}
.rt-play-dock .rt-play-toggle {
  display:inline-flex; align-items:center; justify-content:center; gap:5px;
  min-height:38px; padding:4px 12px; background:#272b23f2; border:1px solid #c4c7ac82;
  border-radius:22px; font:13px Georgia,serif; letter-spacing:.02em;
}
.rt-play-toggle svg {width:12px;height:12px}
.rt-play-toggle[aria-expanded="true"] svg {transform:rotate(180deg)}
.rt-play-options {background:#242820f7; border:1px solid #989d815c; border-radius:9px; padding:7px; pointer-events:auto; max-height:55vh;overflow:auto}
.rt-play-choices {display:grid;grid-template-columns:repeat(2,1fr);gap:2px}
.rt-play-choices.rt-play-encounters {grid-template-columns:1fr}
.rt-play-encounters button:first-child {border-bottom:1px solid #a6ab9347;border-radius:4px 4px 0 0}
.rt-play-choices button,.rt-play-hide {display:flex;align-items:center;gap:7px;min-height:40px;padding:5px 9px;text-align:left;border:0;background:transparent;border-radius:4px}
.rt-play-choices button:disabled {opacity:.4;cursor:default}
.rt-play-dock .rt-play-hide {margin-top:3px;width:100%;min-height:34px;justify-content:center;border-radius:0;border-top:1px solid #a6ab9347;color:#d7d7c8;font-size:12px}
@media (hover:hover){.rt-play-dock button:not(:disabled):hover {background:#414638}}
.rt-play-dock button:focus-visible,.rt-play-dock a:focus-visible {outline:2px solid #ddd5ac;outline-offset:2px}
/* Only the estimate link receives pointer input; all other speech is click-through. */
.rt-speech-layer {position:fixed;inset:0;z-index:2147483001;pointer-events:none}
.rt-wander-caption[hidden] {display:none !important}
.rt-wander-caption {
  --paper:#faf6eb; --edge:#858671;
  position:absolute;left:0;top:0;box-sizing:border-box;width:max-content;
  max-width:min(188px,calc(100vw - 14px)); padding:7px 11px;
  border:1px solid var(--edge); border-radius:10px; background:var(--paper); color:#292d23;
  box-shadow:0 2px 7px #181a1526; font:italic 14px/1.35 Georgia,serif;
  text-align:left;overflow-wrap:anywhere;pointer-events:none;
}
.rt-wander-caption::after {
  content:'';position:absolute;width:8px;height:8px;box-sizing:border-box;
  border:0 solid var(--edge);background:var(--paper);transform:rotate(45deg);
}
.rt-wander-caption[data-tail="left"]::after {left:-5px;top:calc(var(--speech-tip) - 4px);border-width:0 0 1px 1px}
.rt-wander-caption[data-tail="right"]::after {right:-5px;top:calc(var(--speech-tip) - 4px);border-width:1px 1px 0 0}
.rt-wander-caption[data-tail="top"]::after {top:-5px;left:calc(var(--speech-tip) - 4px);border-width:1px 0 0 1px}
.rt-wander-caption[data-tail="bottom"]::after {bottom:-5px;left:calc(var(--speech-tip) - 4px);border-width:0 1px 1px 0}
.rt-wander-caption a {display:block;color:inherit;pointer-events:auto;text-decoration:underline;text-underline-offset:2px}
.rt-wander-caption a:focus-visible {outline:2px solid #717944;outline-offset:2px}
@media(max-width:640px){.rt-wander-caption {max-width:min(162px,calc(100vw - 14px));font-size:13px;padding:6px 10px}}
@media(max-width:850px){body:has(.mobile-call) .rt-play-dock {bottom:calc(65px + env(safe-area-inset-bottom,0px))}}
@media(pointer:coarse){.rt-play-dock .rt-play-toggle,.rt-play-choices button,.rt-play-dock .rt-play-hide {min-height:44px}}

/* Keep the celebration cast on the same foreground plane as Brody. */
.rt-estimate-party[data-playing] { z-index:2147483000; }

/* One small WebGL surface, with the original artwork retained for special scenes and fallback. */
.rt-brody-3d{position:absolute;left:-15%;top:-14%;width:130%;height:120%;pointer-events:none;display:none}
.rt-wander-actor[data-rig="on"] .rt-brody-3d{display:block}
.rt-wander-actor[data-rig="on"] .rt-wander-poses{visibility:hidden}
.rt-wander-actor[data-rig="on"]:has(.rt-wander-body[data-reaction]) .rt-brody-3d,
.rt-wander-actor:is([data-adventure],[data-aside],[data-bear-toss],[data-customer-pose],[data-greeting]) .rt-brody-3d,
.rt-wander[data-hooping] .rt-brody-3d{display:none}
.rt-wander-actor[data-rig="on"]:has(.rt-wander-body[data-reaction]) .rt-wander-poses,
.rt-wander-actor:is([data-adventure],[data-aside],[data-bear-toss],[data-customer-pose],[data-greeting]) .rt-wander-poses,
.rt-wander[data-hooping] .rt-wander-poses{visibility:visible}
.rt-play-hint{margin:5px 7px 8px;padding-bottom:8px;border-bottom:1px solid #a6ab9347;font:italic 12px/1.4 Georgia,serif;color:#edcf9d;max-width:220px}
.review-google-note{display:block;margin-top:7px;font-size:13px;line-height:1.5;color:#7a6043}
