/* Charity Auctions, front-end box. Neutral + brand-tinted; theme-agnostic. */
.cha-box{
  --cha-blue:#2e6cdf; --cha-yellow:#ffd23e; --cha-ink:#23303f; --cha-line:#e3e7ee;
  border:1px solid var(--cha-line); border-radius:16px; padding:1.4rem 1.5rem; margin:1.2rem 0;
  background:#fff; max-width:520px;
}
.cha-state{font-weight:700;margin:0 0 .6rem}
.cha-state--closed{color:#b23}
.cha-box--live{border-color:var(--cha-yellow)}
.cha-box--sealed{border-color:#6b5ce0}
.cha-live-badge{display:inline-block;background:var(--cha-yellow);color:var(--cha-ink);font-weight:800;
  font-size:.7rem;letter-spacing:.06em;text-transform:uppercase;padding:.3rem .7rem;border-radius:100px;margin:0 0 .8rem}
.cha-sealed-badge{background:#6b5ce0;color:#fff}
.cha-current{display:flex;align-items:baseline;justify-content:space-between;gap:1rem}
.cha-label{font-size:.8rem;letter-spacing:.06em;text-transform:uppercase;color:#6a7482;font-weight:700}
.cha-amount{font-family:"Poppins",system-ui,sans-serif;font-size:2rem;font-weight:700;color:var(--cha-ink);line-height:1}
/* the price "lands" when a new bid arrives (class toggled by cha-auction.js) */
.cha-amount.cha-bump{animation:cha-bump .55s cubic-bezier(.22,1,.36,1)}
@keyframes cha-bump{0%{transform:scale(1)}35%{transform:scale(1.14);color:#2e6cdf}100%{transform:scale(1)}}
@media (prefers-reduced-motion:reduce){.cha-amount.cha-bump{animation:none}}
.cha-count{margin:.2rem 0 0;color:#6a7482;font-size:.85rem}
.cha-leader{margin:.35rem 0 0;font-size:.9rem;display:flex;align-items:baseline;gap:.4rem;flex-wrap:wrap}
.cha-leader[hidden]{display:none}
.cha-leader__label{font-size:.72rem;letter-spacing:.06em;text-transform:uppercase;color:#6a7482;font-weight:700}
.cha-leader__name{font-weight:700;color:var(--cha-ink)}
.cha-anon{margin:.1rem 0 0;font-size:.85rem;display:flex;flex-direction:column;gap:.15rem}
.cha-anon label{display:flex;align-items:center;gap:.45rem;font-weight:600;cursor:pointer}
.cha-anon input{width:1.05rem;height:1.05rem;margin:0;flex:0 0 auto}
.cha-anon__hint{font-size:.78rem;color:#6a7482;padding-left:1.5rem;line-height:1.35}
.cha-timer{margin:.9rem 0;font-weight:700;color:var(--cha-blue);font-variant-numeric:tabular-nums;transition:color .3s}
.cha-timer--urgent{color:#c0392b}
@media (prefers-reduced-motion:no-preference){
  .cha-timer--urgent{animation:cha-urgent 1s ease-in-out infinite}
  @keyframes cha-urgent{0%,100%{opacity:1}50%{opacity:.55}}
}
.cha-timer--extended{color:#0a7d3b}
.cha-bidform{margin-top:1rem;display:flex;flex-direction:column;gap:.5rem}
.cha-bidform label{font-weight:600;font-size:.9rem}
.cha-bidform label small{color:#6a7482;font-weight:500}
.cha-bidrow{display:flex;gap:.5rem}
.cha-bidrow input{flex:1;padding:.7rem .8rem;border:1px solid var(--cha-line);border-radius:10px;font-size:1rem}
.cha-bidbtn{background:var(--cha-yellow)!important;color:var(--cha-ink)!important;border:0;border-radius:100px;
  padding:.7rem 1.4rem;font-weight:800;cursor:pointer;white-space:nowrap}
.cha-bidbtn:hover{filter:brightness(.96)}
.cha-bidbtn:disabled{opacity:.6;cursor:default}
.cha-msg{min-height:1.2em;margin:.2rem 0 0;font-weight:600}
.cha-msg.is-ok{color:#0a7d3b}
.cha-msg.is-error{color:#c0392b}
.cha-proxy-note{font-size:.8rem;color:#6a7482;margin:.3rem 0 0}
.cha-buynow-form{margin-top:.9rem;padding-top:.9rem;border-top:1px dashed var(--cha-line)}
.cha-buynowbtn{width:100%;background:#fff!important;color:var(--cha-blue)!important;border:2px solid var(--cha-blue)!important;
  border-radius:100px;padding:.7rem 1.4rem;font-weight:800;cursor:pointer}
.cha-buynowbtn:hover{background:var(--cha-blue)!important;color:#fff!important}
.cha-buynowbtn:disabled{opacity:.6;cursor:default}
.cha-buynow-note{font-size:.8rem;color:#6a7482;margin:.4rem 0 0;text-align:center}
.cha-login a{display:inline-block;margin-top:.8rem;background:var(--cha-blue);color:#fff;padding:.6rem 1.3rem;border-radius:100px;font-weight:700;text-decoration:none}
.cha-history{margin-top:1rem}
.cha-history summary{cursor:pointer;font-weight:600}
.cha-history ul{list-style:none;margin:.6rem 0 0;padding:0;max-height:220px;overflow:auto}
.cha-history li{padding:.4rem 0;border-bottom:1px solid var(--cha-line);font-size:.9rem}
.cha-history .cha-when{color:#8a93a0;font-size:.8rem}
.cha-history em{color:#8a93a0;font-style:normal;font-size:.8rem}
@media (prefers-color-scheme:dark){
  .cha-box{background:#161d29;border-color:#2a3547;--cha-ink:#eef2f8;--cha-line:#2a3547}
  /* On the dark card the semantic colours need to lift off #161d29 to keep
     WCAG AA (4.5:1). Grey secondary text, the accent blue, the timer, and the
     ok/error greens/reds are all too dark against it otherwise. */
  .cha-label,.cha-count,.cha-leader__label,.cha-anon__hint,.cha-proxy-note,
  .cha-buynow-note,.cha-history .cha-when,.cha-history em{color:#9fb0c4}
  .cha-timer{color:#8ab4ff}
  .cha-timer--extended,.cha-msg.is-ok{color:#4ade80}
  .cha-timer--urgent,.cha-msg.is-error,.cha-state--closed{color:#ff9a82}
}

/* ---- Leaderboard / totaliser shortcode ---- */
.cha-leaderboard{border:1px solid #e3e7ee;border-radius:16px;padding:1.4rem 1.5rem;background:#fff;max-width:420px;margin:1.2rem 0}
.cha-leaderboard__total{display:flex;flex-direction:column;gap:.2rem;padding-bottom:1rem;margin-bottom:1rem;border-bottom:1px solid #e3e7ee;text-align:center}
.cha-leaderboard__label{font-size:.8rem;letter-spacing:.06em;text-transform:uppercase;color:#6a7482;font-weight:700}
.cha-leaderboard__amount{font-family:"Poppins",system-ui,sans-serif;font-size:2.2rem;font-weight:700;color:#173e96}
.cha-leaderboard__list{list-style:none;margin:0;padding:0;counter-reset:cha-rank;display:flex;flex-direction:column;gap:.6rem}
.cha-leaderboard__list li{counter-increment:cha-rank}
.cha-leaderboard__list a{display:flex;align-items:center;gap:.7rem;text-decoration:none;color:inherit;
  padding:.35rem .5rem;margin:-.35rem -.5rem;border-radius:10px;transition:background .25s,transform .25s cubic-bezier(.22,1,.36,1)}
.cha-leaderboard__list a:hover{background:#eef2fb;transform:translateX(4px)}
.cha-leaderboard__list a::before{content:counter(cha-rank);flex:0 0 22px;height:22px;border-radius:50%;background:#ffd23e;color:#173e96;
  font-weight:800;font-size:.8rem;display:grid;place-items:center;transition:transform .25s cubic-bezier(.22,1,.36,1)}
.cha-leaderboard__list a:hover::before{transform:scale(1.15)}
.cha-leaderboard__list img{border-radius:8px;flex:0 0 auto}
.cha-leaderboard__name{flex:1;font-weight:600;font-size:.92rem}
.cha-leaderboard__bid{font-weight:700;color:#2e6cdf}
.cha-leaderboard__empty{color:#6a7482;font-size:.9rem;text-align:center;margin:0}

/* ---- Live stream embed (sitewide [cha_livestream] + per-lot) ---- */
.cha-stream{position:relative;width:100%;padding-top:56.25%;border-radius:16px;overflow:hidden;background:#0d1526;margin:1.2rem 0;box-shadow:0 20px 45px -20px rgba(23,62,150,.35)}
.cha-stream iframe{position:absolute;inset:0;width:100%;height:100%;border:0}
.cha-stream--lot{max-width:520px;margin:0 0 1rem}
.cha-stream-empty{color:#6a7482;font-size:.95rem}

/* ---- Shared documents list ([cha_documents]) ---- */
.cha-docs{list-style:none;margin:1.2rem 0;padding:0;display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:.9rem;max-width:820px}
.cha-docs__item a{display:flex;align-items:center;gap:.8rem;padding:1rem 1.1rem;background:#fff;border:1px solid #e3e7ee;border-radius:14px;
  text-decoration:none;color:#23303f;transition:transform .25s cubic-bezier(.22,1,.36,1),box-shadow .25s}
.cha-docs__item a:hover{transform:translateY(-3px);box-shadow:0 14px 30px -14px rgba(23,62,150,.3)}
.cha-docs__icon{flex:0 0 auto;background:#eef2fb;color:#173e96;font-weight:800;font-size:.7rem;letter-spacing:.03em;
  border-radius:9px;padding:.5rem .6rem;min-width:2.6em;text-align:center}
.cha-docs__title{font-weight:600;font-size:.95rem}
.cha-docs-empty{color:#6a7482;font-size:.95rem}

/* ---- Find-my-seat lookup ([cha_find_my_seat]) ---- */
.find-seat{max-width:420px;margin:1.4rem 0;padding:1.4rem 1.6rem;border:1px solid #e3e7ee;border-radius:16px;background:#fff}
.find-seat__form{display:flex;gap:.6rem;flex-wrap:wrap}
.find-seat__form input{flex:1;min-width:200px;padding:.7rem .9rem;border:1px solid #e3e7ee;border-radius:10px;font:inherit}
.find-seat__form button{white-space:nowrap}
.find-seat__result{font-size:1.1rem;font-weight:700;color:#23303f;margin:0 0 .4rem}
.find-seat__mates{color:#6a7482;font-size:.9rem;margin:0}
.find-seat__error{color:#c0392b;font-weight:600}

/* ---- Regular giving ([cha_regular_giving]) ---- */
.rg{max-width:560px;margin:1.4rem 0}
.rg__form{display:flex;flex-direction:column;gap:1.4rem}
.rg__block{border:0;padding:0;margin:0}
.rg__block legend{font-family:"Poppins",system-ui,sans-serif;font-weight:600;font-size:1.05rem;margin-bottom:.7rem;padding:0}
.rg__tiers{display:flex;flex-wrap:wrap;gap:.6rem}
.rg__tier{position:relative;flex:1 1 auto;min-width:88px}
.rg__tier input{position:absolute;opacity:0;pointer-events:none}
.rg__tier>span{display:flex;align-items:center;justify-content:center;gap:.3rem;padding:.75rem .9rem;border:2px solid #e3e7ee;
  border-radius:12px;font-weight:700;color:#23303f;cursor:pointer;transition:border-color .2s,background .2s}
.rg__tier input:checked+span{border-color:#2e6cdf;background:#eef2fb}
.rg__tier--custom>span{font-weight:600}
.rg__custom-input{width:80px;padding:.3rem .5rem;border:1px solid #e3e7ee;border-radius:8px;font:inherit}
.rg__method{display:flex;gap:.7rem;align-items:flex-start;padding:.9rem 1rem;border:2px solid #e3e7ee;border-radius:12px;cursor:pointer;margin-bottom:.6rem;font-size:.92rem;line-height:1.4}
.rg__method:has(input:checked){border-color:#2e6cdf;background:#eef2fb}
.rg__method input{margin-top:.25rem}
.rg__row{display:flex;gap:.8rem;flex-wrap:wrap}
.rg__row label{flex:1;min-width:180px;display:flex;flex-direction:column;gap:.3rem;font-weight:600;font-size:.9rem}
.rg__row input{padding:.7rem .9rem;border:1px solid #e3e7ee;border-radius:10px;font:inherit}
.rg__giftaid{display:flex;gap:.6rem;align-items:flex-start;font-size:.9rem;color:#52606f;line-height:1.4}
.rg__giftaid input{margin-top:.2rem}
.rg__note{font-size:.85rem;color:#6a7482;background:#fff8e1;border-radius:10px;padding:.7rem .9rem}
.rg__submit{background:#ffd23e!important;color:#173e96!important;border:0;border-radius:100px;padding:.85rem 1.6rem;font-weight:800;cursor:pointer;align-self:flex-start}
.rg__error{color:#c0392b;font-weight:600;background:#fdecea;padding:.7rem .9rem;border-radius:10px}
.rg__current{background:#eef7ef;border:1px solid #cfe8d4;border-radius:14px;padding:1.2rem 1.4rem}
.rg__current-lead{margin:0 0 .8rem;font-size:1.05rem}
.rg__cancel{background:#fff;border:1px solid #d9c2c2;color:#c0392b;border-radius:100px;padding:.55rem 1.1rem;font-weight:700;cursor:pointer}
.rg__confirm{text-align:center;background:#fff;border:1px solid #e3e7ee;border-radius:18px;padding:2rem 1.6rem;box-shadow:0 20px 45px -22px rgba(23,62,150,.3)}
.rg__tick{width:56px;height:56px;margin:0 auto 1rem;border-radius:50%;background:#1a8f4c;color:#fff;display:grid;place-items:center;font-size:1.8rem}
.rg__confirm h3{font-family:"Poppins",system-ui,sans-serif;margin:0 0 .6rem}
.rg__bank{display:flex;flex-direction:column;gap:.5rem;max-width:340px;margin:1.2rem auto;text-align:left}
.rg__bank>div{display:flex;justify-content:space-between;gap:1rem;padding:.5rem .8rem;background:#f6f8fc;border-radius:8px}
.rg__bank dt{color:#6a7482;font-size:.85rem;margin:0}
.rg__bank dd{margin:0;font-weight:700}
.rg__bank-ref dd{color:#2e6cdf}
.rg__giftaid-confirm{color:#1a8f4c;font-weight:600}
.rg__small{color:#6a7482;font-size:.85rem}

/* accessibility: visible keyboard focus for the plugin's own controls,
   so bidding, buy-now and watch work by keyboard on any theme */
.cha-bidform input:focus-visible,
.cha-bidbtn:focus-visible,
.cha-buynowbtn:focus-visible,
.cha-watch:focus-visible{
  outline:3px solid #c8a24b;outline-offset:2px}
.cha-watch.is-on{border-color:#c8a24b;color:#8a6d1f}
