/* ============================================================
   UNBOUND Bingo Card — Prairie Path Marketing
   Mobile-first. Scoped under .ppb so it can't leak into the
   site theme or get clobbered by it.
   ============================================================ */

.ppb {
  --pp-black:  #070707;
  --pp-white:  #ffffff;
  --pp-orange: #ff9500;
  --pp-gray:   #808a9f;
  --pp-ebony:  #697268;

  --pp-line:   #e3e6ea;
  --pp-tile:   #ffffff;
  --pp-radius: 8px;
  --pp-found:  var(--pp-orange);

  /* Typography inherits from the site theme on purpose. */
  font-family: inherit;
  color: var(--pp-black);
  max-width: 720px;
  margin-inline: auto;
  padding: 24px 16px 8px;
  box-sizing: border-box;
}

/* Making mobile text more legible at the smaller scale */
@media (max-width: 767px) {
  .ppb__cell-text {
      font-size: 9.5px;
      line-height: 1.2;
      font-weight: bold;
  }
}

.ppb *,
.ppb *::before,
.ppb *::after { box-sizing: border-box; }

.ppb {
    border: 2px solid #ff9500;
    border-radius: 25px;
}

.ppb--found-ebony { --pp-found: var(--pp-ebony); }
.ppb--found-black { --pp-found: var(--pp-black); }

/* ---------- Header ---------- */

.ppb .ppb__head { text-align: center; }

.ppb .ppb__eyebrow {
  margin: 0 0 6px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--pp-gray);
}

.ppb .ppb__title {
  margin: 0;
  font-size: clamp(1.6rem, 7vw, 2.6rem);
  line-height: 1.05;
  font-weight: 700;
  letter-spacing: -0.01em;
}

/* Orange keyline under the title, echoing the Prairie Path deck divider. */
.ppb .ppb__title::after {
  content: "";
  display: block;
  width: 72px;
  height: 3px;
  margin: 14px auto 0;
  background: var(--pp-orange);
}

.ppb .ppb__intro {
  margin: 14px auto 0;
  max-width: 46ch;
  font-size: 0.95rem;
  line-height: 1.5;
  color: #3d4148;
}
.ppb .ppb__intro p { margin: 0; }

.ppb .ppb__progress {
  margin: 16px 0 0;
  min-height: 1em;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--pp-gray);
}
.ppb .ppb__progress b {
  color: var(--pp-orange);
  font-weight: 700;
}

/* ---------- Grid ---------- */

.ppb .ppb__grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: clamp(4px, 1.2vw, 10px);
  margin-top: 22px;
}

.ppb .ppb__cell {
  -webkit-appearance: none;
  appearance: none;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1 / 1;
  width: 100%;
  margin: 0;
  padding: clamp(3px, 1.1vw, 9px);
  border: 1px solid var(--pp-line);
  border-radius: var(--pp-radius);
  background: var(--pp-tile);
  color: var(--pp-black);
  font: inherit;
  font-size: clamp(0.47rem, 2.05vw, 0.82rem);
  line-height: 1.18;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  overflow: hidden;
  transition: background-color .18s ease, border-color .18s ease,
              color .18s ease, transform .12s ease;
}

.ppb .ppb__cell:hover { border-color: var(--pp-gray); }
.ppb .ppb__cell:active { transform: scale(.97); }

.ppb .ppb__cell:focus-visible {
  outline: 3px solid var(--pp-orange);
  outline-offset: 2px;
}

.ppb .ppb__cell-text {
  position: relative;
  z-index: 2;
  display: -webkit-box;
  -webkit-line-clamp: 5;
  line-clamp: 5;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.ppb .ppb__defs {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

/* Found state — the UNBOUND mark daubed on in ink.
   `mix-blend-mode: multiply` is what sells it: the stamp sits ABOVE the text,
   but multiplying orange against near-black leaves the text near-black and
   multiplying it against the white tile leaves orange. Same as real ink on
   a paper card, so nothing has to be dimmed to stay readable. */
.ppb .ppb__stamp {
  position: absolute;
  z-index: 3;
  top: 50%;
  left: 50%;
  width: 104%;
  height: 104%;
  color: var(--pp-found);
  fill: currentColor;
  opacity: 0;
  transform: translate(-50%, -50%) rotate(var(--ppb-rot, -8deg)) scale(.35);
  mix-blend-mode: multiply;
  pointer-events: none;
}
.ppb .ppb__stamp use { fill: currentColor; }

.ppb .ppb__cell[aria-pressed="true"] .ppb__stamp {
  opacity: .9;
  transform: translate(-50%, -50%) rotate(var(--ppb-rot, -8deg)) scale(1);
  animation: ppb-stamp .36s cubic-bezier(.2, 1.5, .35, 1);
}

/* Comes down hard, over-rotated, and settles — a hand pressing a stamp. */
@keyframes ppb-stamp {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) rotate(calc(var(--ppb-rot, -8deg) * 2.4)) scale(1.8);
  }
  55% {
    opacity: .95;
    transform: translate(-50%, -50%) rotate(var(--ppb-rot, -8deg)) scale(.9);
  }
  100% {
    opacity: .9;
    transform: translate(-50%, -50%) rotate(var(--ppb-rot, -8deg)) scale(1);
  }
}

/* No two daubs land at the same angle. Seven variants across 25 tiles, and
   because the board is shuffled the pattern differs per visitor too. */
.ppb .ppb__grid > *:nth-child(7n+1) { --ppb-rot: -11deg; }
.ppb .ppb__grid > *:nth-child(7n+2) { --ppb-rot:   6deg; }
.ppb .ppb__grid > *:nth-child(7n+3) { --ppb-rot:  -4deg; }
.ppb .ppb__grid > *:nth-child(7n+4) { --ppb-rot:  14deg; }
.ppb .ppb__grid > *:nth-child(7n+5) { --ppb-rot:  -8deg; }
.ppb .ppb__grid > *:nth-child(7n+6) { --ppb-rot:   3deg; }
.ppb .ppb__grid > *:nth-child(7n+7) { --ppb-rot: -16deg; }

/* Without multiply the stamp would bury the text, so drop it behind instead. */
@supports not (mix-blend-mode: multiply) {
  .ppb .ppb__stamp,
  .ppb .ppb__cell[aria-pressed="true"] .ppb__stamp { z-index: 1; }
  .ppb .ppb__cell[aria-pressed="true"] .ppb__stamp { opacity: .32; }
}

/* Winning line pulse */
.ppb .ppb__cell.is-winning {
  animation: ppb-pulse 1.1s ease-in-out 2;
}
@keyframes ppb-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(105, 114, 104, 0); }
  50%      { box-shadow: 0 0 0 4px rgba(105, 114, 104, .9); }
}

/* Center free space */
.ppb .ppb__cell--free {
  flex-direction: column;
  justify-content: center;
  gap: 2px;
  background: var(--pp-orange);
  border-color: var(--pp-orange);
  color: var(--pp-white);
}
.ppb .ppb__cell--free:hover { border-color: var(--pp-black); }

.ppb .ppb__fs-logo {
  display: block;
  width: auto;
  max-width: 78%;
  height: clamp(14px, 4.4vw, 26px);
  object-fit: contain;
  flex: none;
}

.ppb .ppb__fs-label {
  font-size: clamp(.4rem, 1.5vw, .58rem);
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  opacity: .85;
  line-height: 1;
}

.ppb .ppb__fs-cta {
  font-size: clamp(.46rem, 1.9vw, .74rem);
  font-weight: 700;
  line-height: 1.1;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ---------- Tools ---------- */

.ppb .ppb__tools { margin-top: 14px; text-align: center; }

.ppb .ppb__reset {
  -webkit-appearance: none;
  appearance: none;
  border: 0;
  background: none;
  padding: 6px 8px;
  font: inherit;
  font-size: .8rem;
  color: var(--pp-gray);
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.ppb .ppb__reset:hover { color: var(--pp-black); }

/* ---------- Buttons ---------- */

.ppb .ppb__btn {
  -webkit-appearance: none;
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--pp-orange);
  border-radius: 999px;
  background: var(--pp-orange);
  color: var(--pp-white);
  padding: 11px 22px;
  font: inherit;
  font-size: .92rem;
  font-weight: 700;
  line-height: 1;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background-color .16s ease, color .16s ease, border-color .16s ease;
}
.ppb .ppb__btn:hover { background: #e88600; border-color: #e88600; color: var(--pp-white); }

.ppb .ppb__btn--ghost {
  background: transparent;
  color: var(--pp-black);
  border-color: var(--pp-line);
}
.ppb .ppb__btn--ghost:hover {
  background: transparent;
  border-color: var(--pp-black);
  color: var(--pp-black);
}

.ppb .ppb__btn:focus-visible {
  outline: 3px solid var(--pp-black);
  outline-offset: 2px;
}

/* ---------- Dialogs ---------- */

.ppb .ppb__overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 16px;
  background: rgba(7, 7, 7, .55);
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
}
.ppb .ppb__overlay[hidden] { display: none; }

.ppb .ppb__dialog {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 420px;
  padding: 26px 22px 22px;
  border-radius: 14px;
  background: var(--pp-white);
  box-shadow: 0 18px 48px rgba(7, 7, 7, .28);
  text-align: center;
  animation: ppb-rise .22s cubic-bezier(.2, .9, .3, 1);
}

@keyframes ppb-rise {
  from { transform: translateY(18px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

.ppb .ppb__dialog-eyebrow {
  margin: 0 0 8px;
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--pp-gray);
}

.ppb .ppb__dialog-title {
  margin: 0;
  font-size: 1.2rem;
  line-height: 1.3;
  font-weight: 700;
}

.ppb .ppb__dialog-title--big {
  font-size: clamp(1.7rem, 8vw, 2.3rem);
  line-height: 1.05;
  letter-spacing: -0.01em;
}

.ppb .ppb__dialog-copy {
  margin: 12px 0 0;
  font-size: .92rem;
  line-height: 1.5;
  color: #3d4148;
}

.ppb .ppb__dialog-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 22px;
}
.ppb .ppb__dialog-actions .ppb__btn { flex: 1 1 auto; }
.ppb .ppb__dialog-actions--stack { flex-direction: column; }

/* ---------- Celebration ---------- */

.ppb .ppb__confetti {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.ppb .ppb__dialog--celebrate {
  padding-top: 34px;
  border-top: 5px solid var(--pp-orange);
}

/* A single orange ring that scales out from behind the heading — the one
   piece of flourish in the module. */
.ppb .ppb__burst {
  position: absolute;
  top: 52px;
  left: 50%;
  width: 130px;
  height: 130px;
  margin: -65px 0 0 -65px;
  border: 3px solid var(--pp-orange);
  border-radius: 50%;
  opacity: 0;
  pointer-events: none;
}
.ppb .ppb__overlay--celebrate:not([hidden]) .ppb__burst {
  animation: ppb-burst .9s cubic-bezier(.15, .8, .3, 1) .1s 1;
}
@keyframes ppb-burst {
  0%   { transform: scale(.2); opacity: .9; }
  100% { transform: scale(2.6); opacity: 0; }
}

.ppb .ppb__hs-cta { display: block; }
.ppb .ppb__hs-cta a { max-width: 100%; }

/* Screen-reader-only live region */
.ppb .ppb__sr {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Larger screens ---------- */

@media (min-width: 560px) {
  .ppb { padding: 40px 24px 16px; }
  .ppb .ppb__cell { border-radius: 10px; }
  .ppb .ppb__overlay { align-items: center; }
  .ppb .ppb__dialog-actions--stack { flex-direction: row-reverse; }
}

@media (prefers-reduced-motion: reduce) {
  .ppb *,
  .ppb *::before,
  .ppb *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  .ppb .ppb__burst { display: none; }
}
