/* Wild Rift Boost — helper.css (built-in site helper widget).
   Load AFTER animations.css (see helper-wiring.md).
   Theme matches style.css: muted dark navy + single gold accent,
   same font stack, same 14px card radius. No libraries.
   Panel max-height 60vh so it never covers the calculator or
   order buttons; the fab sits bottom-right, clear of CTAs. */
:root{
  --helper-bg:#0b0f16; --helper-bg2:#12161f; --helper-line:#242b36;
  --helper-gold:#d9b36a; --helper-gold-soft:#e8c98a; --helper-gold-dark:#171207;
  --helper-teal:#2ec8b8; --helper-text:#eef2f8; --helper-muted:#9aa8c0;
  --helper-radius:14px;
}

/* ---------- floating button ----------
   48px max (Bob, 2026-11-30: the old 56px ? was oversized and sat
   on page content). On mobile it sits bottom-right ABOVE the fixed
   bottom bar (~46px + safe-area) with a clear gap, low enough not
   to cover the order steps or cards; the two shortcut pills
   (Back to top 128px, Back to calculator 180px) stack above it. */
.helper-fab{
  position:fixed; right:20px; bottom:calc(20px + env(safe-area-inset-bottom, 0px));
  z-index:60; min-width:48px; height:48px; border-radius:999px; padding:0 15px 0 13px;
  display:flex; align-items:center; gap:6px;
  border:1px solid var(--helper-gold);
  background:var(--helper-gold); color:var(--helper-gold-dark);
  font-family:system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif;
  font-size:22px; font-weight:800; line-height:1; cursor:pointer;
  box-shadow:0 8px 24px rgba(0,0,0,.45);
  transition:background .15s ease, transform .15s ease;
}
.helper-fab-label{font-size:14px; font-weight:700; letter-spacing:.2px}
.helper-fab:hover{background:var(--helper-gold-soft); transform:translateY(-1px)}
.helper-fab:active{transform:translateY(0)}
.helper-fab:focus-visible{outline:3px solid var(--helper-gold-soft); outline-offset:3px}

/* ---------- panel ---------- */
.helper-panel{
  position:fixed; right:20px; bottom:calc(80px + env(safe-area-inset-bottom, 0px));
  z-index:60; width:min(360px, calc(100vw - 32px));
  max-height:60vh; display:flex; flex-direction:column;
  background:rgba(10,13,19,.97); color:var(--helper-text);
  border:1px solid var(--helper-line); border-radius:var(--helper-radius);
  box-shadow:0 16px 40px rgba(0,0,0,.5);
  font-family:system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif;
  font-size:15px; line-height:1.55; overflow:hidden;
}
.helper-panel[hidden]{display:none}
.helper-panel.helper-open{animation:helper-rise .18s ease both}
@keyframes helper-rise{from{opacity:0; transform:translateY(10px)} to{opacity:1; transform:translateY(0)}}

/* ---------- header ---------- */
.helper-head{
  display:flex; align-items:flex-start; gap:10px;
  padding:14px 16px 10px; border-bottom:1px solid var(--helper-line);
  background:var(--helper-bg2);
}
.helper-head strong{display:block; font-size:15px; color:var(--helper-text)}
.helper-sub{display:block; font-size:13px; color:var(--helper-gold); margin-top:2px}
.helper-close{
  margin-left:auto; flex:0 0 auto; width:32px; height:32px;
  border:1px solid var(--helper-line); border-radius:8px;
  background:transparent; color:var(--helper-muted);
  font-size:20px; line-height:1; cursor:pointer;
}
.helper-close:hover{color:var(--helper-text); border-color:var(--helper-teal)}
.helper-close:focus-visible, .helper-chip:focus-visible,
.helper-input:focus-visible, .helper-send:focus-visible{
  outline:3px solid var(--helper-gold-soft); outline-offset:2px;
}

/* ---------- message log ---------- */
.helper-log{
  flex:1 1 auto; overflow-y:auto; padding:14px 16px;
  display:flex; flex-direction:column; gap:10px; min-height:120px;
}
.helper-msg{
  max-width:92%; padding:10px 12px; border-radius:10px; font-size:14px;
  overflow-wrap:break-word;
}
.helper-msg a{color:var(--helper-gold); overflow-wrap:break-word}
.helper-bot{
  align-self:flex-start; background:var(--helper-bg2);
  border:1px solid var(--helper-line); border-bottom-left-radius:2px;
}
.helper-user{
  align-self:flex-end; background:#2a2113; color:var(--helper-text);
  border:1px solid var(--helper-gold); border-bottom-right-radius:2px;
}

/* ---------- quick replies ---------- */
.helper-quick{
  display:flex; flex-wrap:wrap; gap:6px;
  padding:10px 16px; border-top:1px solid var(--helper-line);
}
.helper-chip{
  background:var(--helper-bg2); color:var(--helper-text);
  border:1px solid var(--helper-line); border-radius:999px;
  padding:7px 12px; font-size:13px; cursor:pointer; min-height:34px;
  font-family:inherit;
}
.helper-chip:hover{border-color:var(--helper-teal); color:var(--helper-teal)}

/* ---------- input row ---------- */
.helper-form{
  display:flex; gap:8px; padding:10px 16px 14px;
  border-top:1px solid var(--helper-line);
}
.helper-input{
  flex:1 1 auto; min-width:0;
  background:#080b11; color:var(--helper-text);
  border:1px solid var(--helper-line); border-radius:8px;
  padding:11px 12px; font-size:15px; min-height:44px;
  font-family:inherit;
}
.helper-input::placeholder{color:var(--helper-muted)}
.helper-send{
  flex:0 0 auto; background:var(--helper-gold); color:var(--helper-gold-dark);
  border:0; border-radius:8px; padding:11px 16px;
  font-weight:700; font-size:15px; cursor:pointer; min-height:44px;
  font-family:inherit;
}
.helper-send:hover{background:var(--helper-gold-soft)}

/* ---------- mobile ---------- */
@media (max-width:700px){
  /* Right-edge column on phones, bottom to top, clear gaps, no
     overlaps: bottom bar 0–46px, helper ? at 58px (48 tall, so it
     ends at 106px), Back to top 128px, Back to calculator 180px.
     The old 236px floated the ? halfway up the screen, over the
     order steps and cards. Panel opens just above the ?. */
  .helper-fab{right:16px; bottom:calc(58px + env(safe-area-inset-bottom, 0px))}
  .helper-panel{
    right:16px; left:16px; width:auto;
    bottom:calc(118px + env(safe-area-inset-bottom, 0px));
  }
}

/* ---------- reduced motion: no slide animation ---------- */
@media (prefers-reduced-motion: reduce){
  .helper-fab, .helper-panel.helper-open, .helper-chip, .helper-send{transition:none!important; animation:none!important}
}
