/* Treatly Glass — the first-time tour (glass-tour.js).
 * The screen dims, the one thing a step is about sits in a lit glass ring,
 * and a black glass card says what it does. */
.gt {
  position: fixed;
  inset: 0;
  z-index: 9000;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.gt.is-in {
  opacity: 1;
}
.gt-dim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.78);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
}
/* with something to show, the ring's own shadow is the dim, with a hole for the thing */
.gt.has-target .gt-dim {
  background: transparent;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}
.gt-ring {
  position: fixed;
  opacity: 0;
  pointer-events: none;
  box-shadow:
    0 0 0 2px rgba(255, 255, 255, 0.95),
    0 0 0 7px rgba(255, 255, 255, 0.12),
    0 0 40px 6px rgba(255, 255, 255, 0.22),
    0 0 0 200vmax rgba(0, 0, 0, 0.78);
  transition:
    left 0.42s cubic-bezier(0.2, 0.9, 0.2, 1),
    top 0.42s cubic-bezier(0.2, 0.9, 0.2, 1),
    width 0.42s cubic-bezier(0.2, 0.9, 0.2, 1),
    height 0.42s cubic-bezier(0.2, 0.9, 0.2, 1),
    border-radius 0.42s,
    opacity 0.25s;
  animation: gtPulse 2.2s ease-in-out infinite;
}
@keyframes gtPulse {
  0%,
  100% {
    box-shadow:
      0 0 0 2px rgba(255, 255, 255, 0.95),
      0 0 0 7px rgba(255, 255, 255, 0.12),
      0 0 40px 6px rgba(255, 255, 255, 0.2),
      0 0 0 200vmax rgba(0, 0, 0, 0.78);
  }
  50% {
    box-shadow:
      0 0 0 2px #fff,
      0 0 0 11px rgba(255, 255, 255, 0.08),
      0 0 56px 10px rgba(255, 255, 255, 0.3),
      0 0 0 200vmax rgba(0, 0, 0, 0.78);
  }
}

/* the card */
.gt-card {
  position: fixed;
  width: min(360px, calc(100vw - 32px));
  padding: 20px 20px 16px;
  border-radius: 28px;
  color: #fff;
  background:
    radial-gradient(120% 70% at 20% -10%, rgba(255, 255, 255, 0.12), transparent 55%),
    linear-gradient(180deg, rgba(30, 30, 34, 0.94), rgba(8, 8, 10, 0.96));
  box-shadow:
    inset 0 1.5px 0.5px rgba(255, 255, 255, 0.4),
    inset 0 0 0 1px rgba(255, 255, 255, 0.1),
    0 30px 80px rgba(0, 0, 0, 0.75);
  -webkit-backdrop-filter: blur(30px) saturate(160%);
  backdrop-filter: blur(30px) saturate(160%);
  transition:
    left 0.42s cubic-bezier(0.2, 0.9, 0.2, 1),
    top 0.42s cubic-bezier(0.2, 0.9, 0.2, 1);
}
.gt-card.is-center {
  left: 50% !important;
  top: 50% !important;
  width: min(380px, calc(100vw - 32px)) !important;
  transform: translate(-50%, -50%);
  text-align: center;
  padding: 26px 22px 18px;
}
.gt-card.is-center .gt-dots,
.gt-card.is-center .gt-acts {
  justify-content: center;
}
.gt-step {
  font: 700 11.5px/1 var(--font, system-ui);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}
.gt-title {
  margin: 8px 0 6px;
  font-family: var(--font-display, var(--font, system-ui));
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.12;
}
.gt-card.is-center .gt-title {
  font-size: 28px;
}
.gt-body {
  margin: 0;
  font-size: 15.5px;
  line-height: 1.45;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.78);
}
.gt-dots {
  display: flex;
  gap: 5px;
  margin: 16px 0 14px;
}
.gt-dots i {
  width: 6px;
  height: 6px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.18);
  transition:
    width 0.3s,
    background 0.3s;
}
.gt-dots i.is-past {
  background: rgba(255, 255, 255, 0.5);
}
.gt-dots i.is-on {
  width: 20px;
  background: #fff;
}
.gt-acts {
  display: flex;
  gap: 8px;
  justify-content: space-between;
}
.gt-btn {
  border: 0;
  height: 46px;
  padding: 0 20px;
  border-radius: 23px;
  font: inherit;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  color: #fff;
  transition: transform 0.15s;
}
.gt-btn:active {
  transform: scale(0.96);
}
.gt-skip {
  background: transparent;
  color: rgba(255, 255, 255, 0.6);
}
.gt-go {
  flex: 0 1 auto;
  min-width: 120px;
  background:
    radial-gradient(120% 90% at 30% 0%, rgba(255, 255, 255, 0.26), transparent 60%),
    linear-gradient(180deg, rgba(58, 58, 66, 0.98), rgba(18, 18, 22, 0.98));
  box-shadow:
    inset 0 1px 0.5px rgba(255, 255, 255, 0.6),
    inset 0 0 0 1px rgba(255, 255, 255, 0.18),
    0 10px 24px rgba(0, 0, 0, 0.5);
}
.gt-go:focus-visible {
  outline: none;
  box-shadow:
    inset 0 1px 0.5px rgba(255, 255, 255, 0.6),
    0 0 0 2px #fff;
}

/* the little pictures */
.gt-pic {
  position: relative;
  display: grid;
  place-items: center;
  height: 132px;
  margin: -4px -4px 14px;
  border-radius: 20px;
  overflow: hidden;
  background:
    radial-gradient(40% 60% at 25% 60%, rgba(185, 167, 245, 0.35), transparent 70%),
    radial-gradient(40% 60% at 80% 30%, rgba(142, 201, 242, 0.3), transparent 70%),
    rgba(255, 255, 255, 0.03);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}
.gt-pic--hello img {
  width: 72px;
  height: 72px;
  filter: drop-shadow(0 0 24px rgba(255, 255, 255, 0.35));
  animation: gtFloat 3.2s ease-in-out infinite;
}
@keyframes gtFloat {
  50% {
    transform: translateY(-6px) rotate(-4deg);
  }
}
.gt-mini {
  position: relative;
  width: 78%;
  padding: 14px 16px;
  border-radius: 20px;
  text-align: left;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.03));
  box-shadow:
    inset 0 1.5px 0.5px rgba(255, 255, 255, 0.45),
    inset 0 0 0 1px rgba(255, 255, 255, 0.1),
    0 14px 30px rgba(0, 0, 0, 0.45);
}
.gt-mini b {
  display: block;
  font-size: 17px;
  font-weight: 800;
}
.gt-mini i {
  display: block;
  margin-top: 2px;
  font-style: normal;
  font-size: 22px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.gt-mini-face {
  position: absolute;
  right: 14px;
  top: 14px;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-size: 13px;
  font-weight: 800;
  background: linear-gradient(135deg, #c05a9b, #7a4fd0);
}
/* a finger-tap ripple on the friend's card */
.gt-mini-tap {
  position: absolute;
  left: 60%;
  top: 58%;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.85);
  box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.5);
  animation: gtTap 2.4s ease-out infinite;
}
@keyframes gtTap {
  0%,
  20% {
    transform: scale(1);
    opacity: 0;
  }
  30% {
    opacity: 1;
    transform: scale(0.85);
    box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.5);
  }
  60% {
    opacity: 0.2;
    transform: scale(1);
    box-shadow: 0 0 0 22px rgba(255, 255, 255, 0);
  }
  100% {
    opacity: 0;
  }
}
/* treats flying into it after the tap */
.gt-fly span {
  position: absolute;
  font-size: 22px;
  opacity: 0;
  animation: gtFly 2.4s cubic-bezier(0.3, 0.8, 0.3, 1) infinite;
}
.gt-fly span:nth-child(1) {
  left: 18%;
  top: 70%;
  animation-delay: 0.7s;
}
.gt-fly span:nth-child(2) {
  left: 78%;
  top: 72%;
  animation-delay: 0.85s;
}
.gt-fly span:nth-child(3) {
  left: 48%;
  top: 82%;
  animation-delay: 1s;
}
@keyframes gtFly {
  0% {
    opacity: 0;
    transform: translateY(20px) scale(0.6);
  }
  25% {
    opacity: 1;
  }
  60% {
    opacity: 1;
    transform: translateY(-46px) scale(1);
  }
  80%,
  100% {
    opacity: 0;
    transform: translateY(-60px) scale(0.4);
  }
}
.gt-mini-check {
  position: absolute;
  right: 16px;
  top: 50%;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  transform: translateY(-50%);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.85);
  animation: gtCheck 3s ease-in-out infinite;
}
@keyframes gtCheck {
  0%,
  55% {
    background: transparent;
  }
  65%,
  90% {
    background: #fff;
    box-shadow:
      inset 0 0 0 2px #fff,
      0 0 20px rgba(255, 255, 255, 0.6);
  }
}
@media (prefers-reduced-motion: reduce) {
  .gt-ring,
  .gt-pic *,
  .gt-pic img {
    animation: none !important;
  }
}

/* live steps: the lit thing really works (tap the task, slide the treats,
   draw on the glass); only the card stays a card */
.gt.is-live,
.gt.is-live .gt-dim {
  pointer-events: none;
}
.gt.is-live .gt-card {
  pointer-events: auto;
}

/* a finger showing what to do */
.gt-finger {
  position: fixed;
  z-index: 2;
  width: 44px;
  height: 44px;
  margin: -22px 0 0 -22px;
  border-radius: 50%;
  pointer-events: none;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 0 0 6px rgba(255, 255, 255, 0.25), 0 8px 24px rgba(0, 0, 0, 0.45);
}
.gt-finger--tap {
  animation: gtFingerTap 1.8s ease-out infinite;
}
@keyframes gtFingerTap {
  0% { transform: scale(1.4); opacity: 0; }
  25% { transform: scale(1); opacity: 1; }
  40% { transform: scale(0.8); box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.55), 0 8px 24px rgba(0, 0, 0, 0.45); }
  75% { transform: scale(1); opacity: 0.9; box-shadow: 0 0 0 26px rgba(255, 255, 255, 0), 0 8px 24px rgba(0, 0, 0, 0.45); }
  100% { opacity: 0; }
}
.gt-finger--slide {
  animation: gtFingerSlide 2.6s cubic-bezier(0.45, 0, 0.25, 1) infinite;
}
@keyframes gtFingerSlide {
  0% { transform: translateX(0) scale(1.3); opacity: 0; }
  12% { transform: translateX(0) scale(0.85); opacity: 1; }
  70% { transform: translateX(var(--run)) scale(0.85); opacity: 1; }
  85% { transform: translateX(var(--run)) scale(1.2); opacity: 0; }
  100% { opacity: 0; }
}
/* the scribble being drawn on the opened task */
.gt-draw {
  position: fixed;
  z-index: 2;
  overflow: visible;
  pointer-events: none;
}
.gt-draw path,
.gt-scribble path {
  fill: none;
  stroke: #ff4d6d;
  stroke-width: 5;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 360;
  stroke-dashoffset: 360;
  filter: drop-shadow(0 0 6px rgba(255, 77, 109, 0.6));
  animation: gtScribble 2.6s linear infinite;
}
.gt-draw circle {
  fill: rgba(255, 255, 255, 0.92);
  stroke: rgba(255, 255, 255, 0.3);
  stroke-width: 8;
}
@keyframes gtScribble {
  0% { stroke-dashoffset: 360; opacity: 1; }
  70% { stroke-dashoffset: 0; opacity: 1; }
  92% { stroke-dashoffset: 0; opacity: 0; }
  100% { stroke-dashoffset: 360; opacity: 0; }
}
.gt-scribble {
  position: absolute;
  left: 8%;
  right: 8%;
  bottom: 6px;
  width: 84%;
  height: 46px;
  overflow: visible;
}
.gt-scribble path { stroke-width: 4; }
.gt-fly span {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: inset 0 1px 0.5px rgba(255, 255, 255, 0.4);
}
@media (prefers-reduced-motion: reduce) {
  .gt-finger,
  .gt-draw { display: none; }
  .gt-draw path,
  .gt-scribble path { animation: none; stroke-dashoffset: 0; }
}
