/* ThaïGuide — challenges.css */

.tg-ch { margin-top:20px; padding-top:20px; border-top:1px solid rgba(255,255,255,.08); }
.tg-ch-hdr { display:flex; align-items:center; justify-content:space-between; margin-bottom:13px; }
.tg-ch-ttl { font-size:.85rem; font-weight:800; color:#f0f4ff; }
.tg-ch-new { background:linear-gradient(135deg,#7c3aed,#5b21b6); border:none; border-radius:10px; color:#fff; font-size:.75rem; font-weight:700; padding:6px 11px; cursor:pointer; }
.tg-ch-grp { font-size:.7rem; font-weight:700; color:rgba(255,255,255,.4); text-transform:uppercase; letter-spacing:.07em; margin:10px 0 6px; }
.tg-ch-card { display:flex; align-items:center; gap:9px; border-radius:12px; padding:11px 13px; margin-bottom:5px; border:1px solid rgba(255,255,255,.07); }
.tg-ch-card-pending { background:rgba(124,58,237,.1); border-color:rgba(124,58,237,.3); }
.tg-ch-card-active  { background:rgba(59,130,246,.08); border-color:rgba(59,130,246,.22); }
.tg-ch-card-won     { background:rgba(22,163,74,.08); border-color:rgba(22,163,74,.22); }
.tg-ch-card-lost    { background:rgba(255,255,255,.03); }
.tg-ch-ci   { font-size:1.45rem; flex-shrink:0; }
.tg-ch-cb   { flex:1; min-width:0; }
.tg-ch-ct   { font-size:.82rem; font-weight:600; color:rgba(255,255,255,.9); margin-bottom:2px; }
.tg-ch-ct strong { color:#fff; }
.tg-ch-cd   { font-size:.72rem; color:rgba(255,255,255,.42); }
.tg-ch-dl   { font-size:.67rem; font-weight:700; background:rgba(255,255,255,.07); border-radius:5px; padding:1px 5px; color:rgba(255,255,255,.45); margin-left:5px; }
.tg-ch-dl-urgent { background:rgba(255,80,0,.2); color:#ff9966; }
.tg-ch-prog { display:flex; align-items:center; gap:5px; margin:4px 0 3px; font-size:.67rem; color:rgba(255,255,255,.45); }
.tg-ch-pb   { flex:1; height:4px; background:rgba(255,255,255,.1); border-radius:3px; overflow:hidden; }
.tg-ch-pf   { height:100%; background:linear-gradient(90deg,#3b82f6,#1d4ed8); border-radius:3px; transition:width .5s; }
.tg-ch-ok   { background:linear-gradient(135deg,#16a34a,#15803d); border:none; border-radius:8px; color:#fff; width:30px; height:30px; cursor:pointer; font-size:.9rem; font-weight:700; flex-shrink:0; }
.tg-ch-no   { background:rgba(255,255,255,.07); border:1px solid rgba(255,255,255,.14); border-radius:8px; color:rgba(255,255,255,.5); width:30px; height:30px; cursor:pointer; flex-shrink:0; }
.tg-ch-empty { text-align:center; padding:18px; color:rgba(255,255,255,.32); font-size:.81rem; }

/* Modal */
.tg-ch-ov { position:fixed; inset:0; background:rgba(0,0,0,.72); z-index:2147483648; display:flex; align-items:flex-end; justify-content:center; padding-bottom:max(20px,env(safe-area-inset-bottom,20px)); opacity:0; transition:opacity .3s; }
.tg-ch-ov-in { opacity:1; }
.tg-ch-box { background:#1a2744; border:1.5px solid rgba(255,255,255,.14); border-radius:22px 22px 14px 14px; padding:26px 22px; width:100%; max-width:460px; position:relative; transform:translateY(100px); transition:transform .35s cubic-bezier(.34,1.56,.64,1); }
.tg-ch-ov-in .tg-ch-box { transform:translateY(0); }
.tg-ch-xclose { position:absolute; top:13px; right:14px; background:rgba(255,255,255,.07); border:1px solid rgba(255,255,255,.14); border-radius:50%; width:30px; height:30px; color:rgba(255,255,255,.55); font-size:.95rem; cursor:pointer; }
.tg-ch-mttl { font-size:1.05rem; font-weight:800; color:#fff; margin-bottom:16px; }
.tg-ch-lbl  { display:block; font-size:.7rem; font-weight:700; color:rgba(255,255,255,.4); text-transform:uppercase; letter-spacing:.07em; margin:13px 0 6px; }
.tg-ch-sel  { width:100%; background:rgba(255,255,255,.07); border:1.5px solid rgba(255,255,255,.18); border-radius:10px; color:#fff; padding:9px 13px; font-size:.88rem; }
.tg-ch-tgrid { display:flex; gap:7px; }
.tg-ch-tb   { flex:1; background:rgba(255,255,255,.05); border:1.5px solid rgba(255,255,255,.11); border-radius:11px; color:rgba(255,255,255,.55); padding:9px 5px; font-size:1.15rem; cursor:pointer; line-height:1.3; text-align:center; }
.tg-ch-tb small { display:block; font-size:.66rem; font-weight:700; margin-top:3px; }
.tg-ch-tb-on { background:rgba(124,58,237,.2); border-color:rgba(124,58,237,.55); color:#c4b5fd; }
.tg-ch-vals { display:flex; gap:7px; flex-wrap:wrap; }
.tg-ch-vb   { background:rgba(255,255,255,.05); border:1.5px solid rgba(255,255,255,.11); border-radius:9px; color:rgba(255,255,255,.55); padding:7px 13px; font-size:.8rem; font-weight:700; cursor:pointer; }
.tg-ch-vb-on { background:rgba(124,58,237,.2); border-color:rgba(124,58,237,.5); color:#c4b5fd; }
.tg-ch-send { width:100%; margin-top:18px; background:linear-gradient(135deg,#7c3aed,#5b21b6); border:none; border-radius:13px; color:#fff; font-size:.95rem; font-weight:800; padding:13px; cursor:pointer; box-shadow:0 4px 16px rgba(124,58,237,.35); }
.tg-ch-send:disabled { opacity:.6; cursor:not-allowed; }

/* Toast */
.tg-ch-toast { position:fixed; bottom:96px; left:50%; transform:translateX(-50%) translateY(20px); background:linear-gradient(135deg,#7c3aed,#5b21b6); color:#fff; border-radius:11px; padding:11px 22px; font-size:.88rem; font-weight:700; z-index:2147483648; opacity:0; transition:opacity .25s,transform .25s; }
.tg-ch-toast-in { opacity:1; transform:translateX(-50%) translateY(0); }
