/* Little Big Lab — “Buy the builders a bubble tea” support component
   Production: variant A only (teal pill with cup).
   Brand fonts: Fredoka (display), Nunito (body)
   Palette: #2c3e50 text, #ff6b6b Sofie, #4ecdc4 Bella, #a55eea Wrinkles,
            #0b9e8e / #3cb8ae teal, #feca57 gold, #f0f4f8 paper
*/

.lbl-support {
  --lbl-ink: #2c3e50;
  --lbl-muted: #5a6b7b;
  --lbl-quiet: #8fa4b8;
  --lbl-sofie: #ff6b6b;
  --lbl-bella: #4ecdc4;
  --lbl-bella-deep: #3cb8ae;
  --lbl-wrinkles: #a55eea;
  --lbl-gold: #feca57;
  --lbl-gold-deep: #d49a00;
  --lbl-paper: #fffdf9;
  --lbl-mint: #e0f8f5;
  font-family: "Nunito", sans-serif;
}

.lbl-cup {
  display: block;
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  overflow: visible;
}

/* ---------- Footer cluster ---------- */
.lbl-support--footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin: 18px 0 6px;
}

.lbl-support__cta {
  position: relative;
  overflow: visible;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  text-decoration: none;
  color: var(--lbl-ink);
  line-height: 1.15;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  background: var(--lbl-paper);
  border: 2px solid var(--lbl-bella);
  border-radius: 999px;
  padding: 8px 18px 8px 10px;
  min-height: 44px;
  box-shadow: 0 4px 0 var(--lbl-bella-deep), 0 8px 16px rgba(44, 62, 80, 0.08);
  transform: translateY(0);
  transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.lbl-support__label {
  font-family: "Fredoka", sans-serif;
  font-weight: 600;
  letter-spacing: 0.01em;
  font-size: 15.5px;
  color: var(--lbl-ink);
}

.lbl-support__cta:hover,
.lbl-support__cta:focus-visible,
.lbl-support__cta.is-hover {
  background: var(--lbl-mint);
  transform: translateY(-2px);
  box-shadow: 0 6px 0 var(--lbl-bella-deep), 0 12px 20px rgba(44, 62, 80, 0.1);
  animation: lbl-wiggle 0.55s ease both;
}

.lbl-support__grownups {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
  color: var(--lbl-quiet);
  letter-spacing: 0.01em;
}

.lbl-support__grownups a {
  color: inherit;
  font-weight: 800;
  text-decoration: none;
}

.lbl-support__grownups a:hover {
  color: var(--lbl-sofie);
}

/* ---------- Shell: icon button in the top bar ---------- */
.lbl-support__iconbtn {
  --lbl-ink: #2c3e50;
  --lbl-bella: #4ecdc4;
  --lbl-bella-deep: #3cb8ae;
  --lbl-gold: #feca57;
  --lbl-gold-deep: #d49a00;
  --lbl-mint: #e0f8f5;
  --lbl-paper: #fffdf9;
  position: relative;
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  text-decoration: none;
  color: inherit;
  background: #fffdf9;
  border: 2px solid #4ecdc4;
  border-radius: 50%;
  overflow: visible;
  box-shadow: 0 2px 0 #3cb8ae;
  transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.lbl-support__iconbtn .lbl-cup {
  width: 28px;
  height: 28px;
}

.lbl-support__icon-label {
  display: none;
}

.lbl-support__iconbtn:hover,
.lbl-support__iconbtn:focus-visible,
.lbl-support__iconbtn.is-hover {
  background: #e0f8f5;
  transform: translateY(-1px);
  animation: lbl-wiggle 0.55s ease both;
}

/* Native tooltip is title=""; also a CSS tooltip for a more on-brand look */
.lbl-support__iconbtn[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  min-width: 190px;
  max-width: 240px;
  padding: 8px 10px;
  background: #1a252f;
  color: #fff;
  font-family: "Nunito", "Inter", sans-serif;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
  border-radius: 10px;
  box-shadow: 0 8px 18px rgba(16, 54, 85, 0.2);
  opacity: 0;
  pointer-events: none;
  transform: translateY(-4px);
  transition: opacity 0.16s ease, transform 0.16s ease;
  z-index: 20;
  text-align: left;
}

.lbl-support__iconbtn[data-tooltip]:hover::after,
.lbl-support__iconbtn[data-tooltip]:focus-visible::after,
.lbl-support__iconbtn[data-tooltip].is-hover::after {
  opacity: 1;
  transform: translateY(0);
}

.lbl-support__shell-note {
  margin: 10px 2px 0;
  font-family: "Nunito", "Inter", sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: #8fa4b8;
  text-align: right;
  line-height: 1.4;
}

.lbl-support__shell-note a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px dotted #cfd9e3;
}

.lbl-support__shell-note a:hover,
.lbl-support__shell-note a:focus-visible {
  color: #0b9e8e;
  border-bottom-color: #4ecdc4;
}

/* Focus rings — match LBL teal */
.lbl-support__cta:focus-visible,
.lbl-support__iconbtn:focus-visible,
.lbl-support__shell-note a:focus-visible,
.lbl-support__grownups a:focus-visible {
  outline: 2px solid #4ecdc4;
  outline-offset: 3px;
}

/* Pearl bounce (only when the parent is hovered / .is-hover) */
.lbl-support__cta:hover .lbl-cup__pearl,
.lbl-support__cta:focus-visible .lbl-cup__pearl,
.lbl-support__cta.is-hover .lbl-cup__pearl,
.lbl-support__iconbtn:hover .lbl-cup__pearl,
.lbl-support__iconbtn:focus-visible .lbl-cup__pearl,
.lbl-support__iconbtn.is-hover .lbl-cup__pearl {
  animation: lbl-pearl-bounce 0.7s ease-in-out both;
}

.lbl-cup__pearl.p2 { animation-delay: 0.07s; }
.lbl-cup__pearl.p3 { animation-delay: 0.14s; }
.lbl-cup__pearl.p4 { animation-delay: 0.05s; }
.lbl-cup__pearl.p5 { animation-delay: 0.18s; }

@keyframes lbl-wiggle {
  0%   { transform: translateY(-2px) rotate(0deg); }
  25%  { transform: translateY(-2px) rotate(-5deg); }
  50%  { transform: translateY(-2px) rotate(4deg); }
  75%  { transform: translateY(-2px) rotate(-2.5deg); }
  100% { transform: translateY(-2px) rotate(0deg); }
}

@keyframes lbl-pearl-bounce {
  0%, 100% { transform: translateY(0); }
  40%      { transform: translateY(-3.2px); }
  70%      { transform: translateY(0.8px); }
}

@media (prefers-reduced-motion: reduce) {
  .lbl-support__cta,
  .lbl-support__iconbtn,
  .lbl-cup__pearl,
  .lbl-support__iconbtn[data-tooltip]::after {
    animation: none !important;
    transition: none !important;
  }

  .lbl-support__cta:hover,
  .lbl-support__cta.is-hover,
  .lbl-support__iconbtn:hover,
  .lbl-support__iconbtn.is-hover {
    transform: translateY(-1px);
  }
}

@media (max-width: 640px) {
  .lbl-support__label {
    font-size: 14.5px;
  }

  .lbl-support__shell-note {
    text-align: left;
    font-size: 12px;
  }

  .lbl-support__iconbtn[data-tooltip]::after {
    right: 0;
    left: auto;
    min-width: 160px;
  }
}
