/* FanFundU · the "you're in" moment, shared by the store hand-off page (/linkout/bridge, LinkoutEndpoints.BridgeHtml)
   and the signed-in screen on /signin (SignIn.cshtml #si-view-redirecting), so both feel the same (product decision,
   2026-10-24): a dark header where the program's logo connects to a tile (the store, or the person signing in) through a
   pulse that lands on a check, a sheen, rising sparks, and the program's tagline word by word; then a bar that fills while
   the page moves on, and a button to go now. Each page lays out its own card and title around these pieces.
   The bar's length is the page's --ffu-br-delay (how long it waits before moving on). The program's colour is
   --brand-primary (program-config.js on the site's pages; the hand-off page sets it from ProgramCfg.BrandColor), and its
   glows and deeper shade are mixed from it, so a co-branded program's pages carry its colour. */

.ffu-br-head {
  position: relative; overflow: hidden; text-align: center; padding: 30px 24px 26px;
  background: radial-gradient(120% 100% at 50% 0%, #3b1520 0%, #1f2433 55%, #151926 100%);
}
.ffu-br-sheen {
  position: absolute; top: -60%; left: -70%; width: 45%; height: 220%; pointer-events: none;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.10), transparent); transform: rotate(18deg);
  animation: ffuBrSheen 2.2s .5s ease-in-out both;
}
.ffu-br-sparks i {
  position: absolute; bottom: -6px; width: 5px; height: 5px; border-radius: 50%; background: #F99D20; opacity: 0;
  animation: ffuBrSpark 2.8s ease-out infinite;
}
.ffu-br-sparks i:nth-child(1) { left: 12%; animation-delay: .4s; }
.ffu-br-sparks i:nth-child(2) { left: 26%; animation-delay: 1.3s; background: #F2E4B1; }
.ffu-br-sparks i:nth-child(3) { left: 44%; animation-delay: .9s; width: 4px; height: 4px; }
.ffu-br-sparks i:nth-child(4) { left: 61%; animation-delay: 1.8s; background: #F2E4B1; }
.ffu-br-sparks i:nth-child(5) { left: 77%; animation-delay: .6s; }
.ffu-br-sparks i:nth-child(6) { left: 90%; animation-delay: 1.5s; width: 4px; height: 4px; background: #F2E4B1; }

/* The connection: program ⇢ (pulse, check) ⇢ tile */
.ffu-br-link { position: relative; display: flex; align-items: center; justify-content: center; gap: 16px; margin: 2px 0 20px; }
.ffu-br-prog { display: flex; align-items: center; justify-content: center; width: 120px; height: 76px; animation: ffuBrFromL .55s .1s ease-out both; }
.ffu-br-prog img { display: block; max-width: 120px; max-height: 40px; width: auto; height: auto; }
.ffu-br-prog-name { font-size: 17px; font-weight: 900; color: #F2E4B1; }
.ffu-br-wire { position: relative; flex-shrink: 0; width: 96px; height: 2px; background: repeating-linear-gradient(90deg, rgba(242,228,177,.45) 0 6px, transparent 6px 12px); }
.ffu-br-pulse {
  position: absolute; top: 50%; left: 0; width: 10px; height: 10px; margin-top: -5px; border-radius: 50%;
  background: #F99D20; box-shadow: 0 0 14px 5px rgba(249,157,32,.65); animation: ffuBrTravel 1.2s .3s ease-in-out infinite;
}
.ffu-br-check {
  position: absolute; left: 50%; top: 50%; z-index: 1; width: 30px; height: 30px; margin: -15px 0 0 -15px;
  display: flex; align-items: center; justify-content: center; border-radius: 50%;
  background: var(--brand-primary); color: #fff; box-shadow: 0 0 0 5px color-mix(in srgb, var(--brand-primary) 28%, transparent), 0 4px 14px rgba(0,0,0,.35);
  animation: ffuBrPop .5s .75s cubic-bezier(.2,1.6,.4,1) both;
}
.ffu-br-store {
  position: relative; flex-shrink: 0; width: 76px; height: 76px; border-radius: 20px; overflow: hidden; background: #fff;
  box-shadow: 0 0 0 4px rgba(255,255,255,.08), 0 12px 34px color-mix(in srgb, var(--brand-primary) 45%, transparent);
  animation: ffuBrFromR .55s .1s ease-out both, ffuBrGlow 2.2s 1.3s ease-in-out infinite;
}
.ffu-br-store img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #fff; padding: 10px; box-sizing: border-box; }

/* The program's tagline, word by word, the last word lit */
.ffu-br-tagline { margin: 0 0 8px; font-size: 13px; font-weight: 900; letter-spacing: .22em; text-transform: uppercase; color: #F2E4B1; }
.ffu-br-tagline span { display: inline-block; margin: 0 .3em; opacity: 0; animation: ffuBrWord .45s cubic-bezier(.2,1.4,.4,1) forwards; animation-delay: calc(.95s + var(--i) * .22s); }
.ffu-br-tagline span:last-child { color: #F99D20; text-shadow: 0 0 18px rgba(249,157,32,.55); }

/* Moving on: the bar fills for --ffu-br-delay, and the button goes now */
.ffu-br-bar { display: block; height: 6px; border-radius: 999px; background: rgba(28,33,48,.08); overflow: hidden; }
.ffu-br-bar i { display: block; height: 100%; width: 0; border-radius: inherit; background: linear-gradient(90deg, var(--brand-primary), #F99D20); box-shadow: 0 0 10px rgba(249,157,32,.5); animation: ffuBrFill var(--ffu-br-delay, 2s) linear forwards; }
.ffu-br-continue {
  appearance: none; border: 0; cursor: pointer; font-family: 'REM', sans-serif; font-size: 15px; font-weight: 800; color: #fff;
  background: linear-gradient(180deg, var(--brand-primary), color-mix(in srgb, var(--brand-primary) 82%, #000)); border-radius: 12px; padding: 12px 18px; min-height: 46px; width: 100%;
  box-shadow: 0 8px 22px color-mix(in srgb, var(--brand-primary) 35%, transparent);
}

@keyframes ffuBrIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes ffuBrPop { from { opacity: 0; transform: scale(.4); } to { opacity: 1; transform: scale(1); } }
@keyframes ffuBrFill { to { width: 100%; } }
@keyframes ffuBrSheen { from { left: -70%; } to { left: 130%; } }
@keyframes ffuBrSpark { 0% { opacity: 0; transform: translateY(0) scale(.6); } 20% { opacity: .9; } 100% { opacity: 0; transform: translateY(-130px) scale(1); } }
@keyframes ffuBrTravel { 0% { left: 0; opacity: 0; } 15% { opacity: 1; } 85% { opacity: 1; } 100% { left: calc(100% - 10px); opacity: 0; } }
@keyframes ffuBrFromL { from { opacity: 0; transform: translateX(-24px); } to { opacity: 1; transform: none; } }
@keyframes ffuBrFromR { from { opacity: 0; transform: translateX(24px) scale(.9); } to { opacity: 1; transform: none; } }
@keyframes ffuBrGlow { 0%, 100% { box-shadow: 0 0 0 4px rgba(255,255,255,.08), 0 12px 34px color-mix(in srgb, var(--brand-primary) 45%, transparent); } 50% { box-shadow: 0 0 0 6px rgba(249,157,32,.22), 0 12px 44px rgba(249,157,32,.55); } }
@keyframes ffuBrWord { from { opacity: 0; transform: translateY(8px) scale(.8); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  .ffu-br-head *, .ffu-br-bar i { animation-duration: 0s !important; animation-delay: 0s !important; }
  .ffu-br-bar i { width: 100%; }
}
@media (max-width: 420px) {
  .ffu-br-link { gap: 10px; }
  .ffu-br-prog { width: 92px; }
  .ffu-br-prog img { max-width: 92px; max-height: 32px; }
  .ffu-br-wire { width: 64px; }
}
