/* ============================================================
   WCMA App — premium mobile-first shell
   ============================================================ */
body.app{
  display:flex;justify-content:center;min-height:100vh;
  background:
    radial-gradient(1100px 600px at 50% -12%, #152230 0%, transparent 60%),
    var(--ink);
}
/* #app is the flex item: it must be allowed to shrink below its content */
#app{width:100%;min-width:0;display:flex;justify-content:center}
.phone{
  width:100%;max-width:520px;min-width:0;min-height:100vh;
  display:flex;flex-direction:column;position:relative;
  background:var(--ink);
  border-inline:1px solid var(--line);
}

/* ---------- App bar ---------- */
.appbar{
  position:sticky;top:0;z-index:30;
  display:flex;align-items:center;gap:10px;min-width:0;
  padding:14px 18px;
  background:rgba(11,14,18,.85);backdrop-filter:blur(16px);
  border-bottom:1px solid var(--line);
}
.appbar .mark{width:30px;height:30px;color:var(--bone)}
.appbar .brand{font-size:11.5px;font-weight:800;letter-spacing:.06em;line-height:1.2;
  white-space:nowrap;min-width:0;overflow:hidden;text-overflow:ellipsis}
.appbar .brand small{display:block;font-size:8.5px;font-weight:700;color:var(--bone-dim);letter-spacing:.1em;white-space:nowrap}
.appbar .chip{padding:3px 9px;font-size:10.5px}
.appbar .iconbtn{width:33px;height:33px}
@media (max-width:430px){
  .appbar{gap:8px;padding:12px 14px}
  .appbar .brand{display:none}          /* the mark carries the brand on small screens */
  .appbar .chip{padding:3px 8px;font-size:10px}
}
.appbar .spacer{flex:1}
.iconbtn{
  display:grid;place-items:center;width:36px;height:36px;border-radius:10px;
  border:1px solid var(--line);background:var(--ink-2);color:var(--bone-dim);
  font-size:12px;font-weight:800;transition:all .3s var(--ease);
}
.iconbtn:hover{color:var(--ray);border-color:rgba(63,211,220,.35)}

/* ---------- View ---------- */
#view{flex:1;padding:20px 18px 26px;animation:viewIn .45s var(--ease)}
@keyframes viewIn{from{opacity:0;transform:translateY(14px)}to{opacity:1;transform:none}}

.vh{display:flex;align-items:baseline;justify-content:space-between;gap:10px;margin-bottom:14px}
.vh h1{font-size:22px;font-weight:800;letter-spacing:-.01em}
.vh .sub{color:var(--bone-dim);font-size:13px}
.section-t{font-size:12px;font-weight:800;letter-spacing:.14em;text-transform:uppercase;
  color:var(--bone-dim);margin:24px 0 10px}
.section-t:first-child{margin-top:0}

/* ---------- Cards ---------- */
.card{
  background:linear-gradient(165deg,var(--ink-3),var(--ink-2));
  border:1px solid var(--line);border-radius:var(--radius);
  padding:16px;margin-bottom:12px;
}
.card.flat{background:var(--ink-2)}
.card h3{font-size:15px;font-weight:800;margin-bottom:4px}
.card .muted{color:var(--bone-dim);font-size:13px}

/* ---------- Tab bar ---------- */
.tabbar{
  position:sticky;bottom:0;z-index:30;display:flex;
  background:rgba(13,17,23,.92);backdrop-filter:blur(16px);
  border-top:1px solid var(--line);
  padding:6px 4px calc(6px + env(safe-area-inset-bottom));
}
.tab{
  flex:1;display:flex;flex-direction:column;align-items:center;gap:3px;
  padding:8px 2px;font-size:10.5px;font-weight:700;color:var(--bone-dim);
  border-radius:12px;transition:color .3s var(--ease);
}
.tab .ic{width:21px;height:21px}
.tab.active{color:var(--ray)}
.tab.active .ic{filter:drop-shadow(0 0 8px rgba(63,211,220,.55))}

/* ---------- Role select ---------- */
.roles{min-height:calc(100vh - 63px);display:flex;flex-direction:column;justify-content:center;padding:32px 22px;gap:14px}
.roles .mark-big{width:74px;height:74px;margin:0 auto 6px;color:var(--bone)}
.roles h1{text-align:center;font-size:24px;font-weight:800}
.roles .lead{text-align:center;color:var(--bone-dim);font-size:14px;margin-bottom:14px}
.rolebtn{
  display:flex;align-items:center;gap:16px;text-align:start;
  padding:20px;border-radius:var(--radius);
  background:linear-gradient(165deg,var(--ink-3),var(--ink-2));
  border:1px solid var(--line);transition:all .35s var(--ease);
}
.rolebtn:hover{border-color:rgba(63,211,220,.4);transform:translateY(-2px);box-shadow:0 14px 40px rgba(0,0,0,.35)}
.rolebtn .ic{width:40px;height:40px;color:var(--ray)}
.rolebtn b{display:block;font-size:16px}
.rolebtn span{display:block;color:var(--bone-dim);font-size:12.5px;margin-top:2px}
.demonote{text-align:center;color:var(--bone-dim);font-size:12px;margin-top:10px}

/* ---------- Level hero (trainee home) ---------- */
.levelhero{display:flex;align-items:center;gap:18px}
.ringwrap{position:relative;width:104px;height:104px;flex:none}
.ringwrap svg{width:104px;height:104px;transform:rotate(-90deg)}
.ringwrap .rbg{fill:none;stroke:var(--ink-4);stroke-width:7}
.ringwrap .rfg{fill:none;stroke:var(--tc,var(--ray));stroke-width:7;stroke-linecap:round;
  transition:stroke-dashoffset 1.4s var(--ease)}
.ringlabel{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center}
.ringlabel b{font-size:22px;line-height:1}
.ringlabel span{font-size:9px;letter-spacing:.18em;color:var(--bone-dim);font-weight:800;margin-top:3px}
.levelinfo{flex:1;min-width:0}
.tiername{font-size:19px;font-weight:800;color:var(--tc,var(--ray));letter-spacing:.06em}
.xpline{display:flex;justify-content:space-between;font-size:12px;color:var(--bone-dim);margin:8px 0 6px}
.xpline b{color:var(--bone)}
.toNext{font-size:12px;color:var(--bone-dim);margin-top:6px}
.toNext b{color:var(--tc,var(--ray))}

/* requirement list */
.reqs li{display:flex;align-items:center;gap:10px;padding:8px 0;border-bottom:1px solid var(--line);font-size:13.5px}
.reqs li:last-child{border-bottom:0}
.reqs .ic{width:19px;height:19px;color:var(--bone-dim)}
.reqs li.done{color:var(--bone-dim)}
.reqs li.done .ic{color:var(--green)}

/* focus / session rows */
.rowcard{display:flex;align-items:center;gap:14px}
.rowcard .ic{width:26px;height:26px;color:var(--ray)}
.rowcard .grow{flex:1;min-width:0}
.rowcard b{display:block;font-size:14.5px}
.rowcard span{display:block;font-size:12.5px;color:var(--bone-dim)}
.timechip{font-size:12px;font-weight:800;color:var(--ray);background:var(--ray-soft);
  padding:4px 10px;border-radius:8px;white-space:nowrap}

/* achievements strip */
.astrip{display:flex;gap:10px;overflow-x:auto;padding-bottom:4px}
.astrip .achmini{
  flex:none;display:flex;align-items:center;gap:9px;padding:10px 14px;border-radius:14px;
  background:var(--ink-2);border:1px solid var(--line);font-size:12.5px;font-weight:700;
}
.achmini .ic{width:20px;height:20px;color:var(--rc,var(--ray))}

/* ---------- Session parts ---------- */
.parts li{display:flex;align-items:center;gap:12px;padding:9px 0;border-bottom:1px solid var(--line);font-size:14px}
.parts li:last-child{border-bottom:0}
.pdot{width:11px;height:11px;border-radius:50%;flex:none;border:2px solid var(--line-strong)}
.parts .done .pdot{background:var(--green);border-color:var(--green)}
.parts .current .pdot{background:var(--ray);border-color:var(--ray);animation:pulse 1.8s infinite}
.parts .done{color:var(--bone-dim)}
.parts .current{font-weight:800}
.parts .pending{color:var(--bone-dim)}
@keyframes pulse{0%,100%{box-shadow:0 0 0 0 rgba(63,211,220,.5)}55%{box-shadow:0 0 0 7px rgba(63,211,220,0)}}

.skillticks{display:flex;flex-wrap:wrap;gap:8px;margin-top:8px}
.skilltick{font-size:12.5px;font-weight:700;padding:5px 11px;border-radius:99px;border:1px solid var(--line);color:var(--bone-dim)}
.skilltick.ok{color:var(--green);border-color:rgba(87,184,119,.4);background:rgba(87,184,119,.09)}

.coachnote{display:flex;gap:12px;align-items:flex-start}
.coachnote .avatar{width:36px;height:36px;border-radius:50%;flex:none;display:grid;place-items:center;
  background:var(--ray-soft);color:var(--ray);font-weight:800;font-size:14px}
.coachnote p{font-size:13.5px;line-height:1.65}
.coachnote .who{font-size:11.5px;color:var(--bone-dim);margin-top:5px}

/* history */
.hrow{display:flex;align-items:center;gap:12px;padding:11px 0;border-bottom:1px solid var(--line)}
.hrow:last-child{border-bottom:0}
.hrow .d{font-size:11.5px;color:var(--bone-dim);width:64px;flex:none}
.hrow .n{flex:1;font-size:13.5px}
.hrow .xp{font-size:12px;font-weight:800;color:var(--ray);background:var(--ray-soft);padding:3px 9px;border-radius:8px;white-space:nowrap}

/* ---------- Belt strip ---------- */
.beltstrip{display:flex;align-items:center;gap:14px}
.beltvis{width:64px;height:18px;border-radius:5px;flex:none;position:relative;
  background:var(--bc,#ccc);box-shadow:inset 0 -3px 6px rgba(0,0,0,.3)}
.beltvis::after{content:'';position:absolute;top:0;bottom:0;inset-inline-end:9px;width:9px;background:rgba(0,0,0,.35)}
.beltinfo{flex:1}
.beltinfo b{font-size:14.5px}
.beltinfo .muted{font-size:12px}

/* ---------- Current Map (skill tree) ---------- */
.treehead{display:flex;align-items:center;gap:12px;margin-bottom:6px}
.treehead .mark{width:34px;height:34px;color:var(--ray)}
.branch{margin-bottom:16px}
.branch .bh{display:flex;align-items:center;justify-content:space-between;margin-bottom:8px}
.branch .bh b{font-size:13.5px;letter-spacing:.04em}
.branch .bh span{font-size:11.5px;color:var(--bone-dim);font-weight:700}
.branch .bbar{margin-bottom:12px}
.chain{display:flex;align-items:flex-start;overflow-x:auto;padding:4px 2px 8px}
.node{min-width:78px;flex:none;display:flex;flex-direction:column;align-items:center;text-align:center;gap:7px}
.dot{
  width:46px;height:46px;border-radius:50%;display:grid;place-items:center;position:relative;
  border:2px solid var(--line-strong);background:var(--ink-2);color:var(--bone-dim);
  transition:all .4s var(--ease);
}
.dot .ic{width:20px;height:20px}
.node small{font-size:11px;line-height:1.35;color:var(--bone-dim);font-weight:700;max-width:80px}
.node.s-mastered .dot{border-color:var(--gold);color:var(--gold);box-shadow:0 0 20px var(--gold-soft)}
.node.s-mastered small{color:var(--gold)}
.node.s-completed .dot{border-color:var(--ray);color:var(--ray)}
.node.s-completed small{color:var(--bone)}
.node.s-inprogress .dot{border-color:var(--ray);color:var(--ray);animation:pulse 2.2s infinite}
.node.s-locked .dot{opacity:.4}
.node.s-locked small{opacity:.5}
.link{flex:1;min-width:16px;height:2px;background:var(--line-strong);margin-top:23px}
.link.on{background:linear-gradient(90deg,var(--ray),var(--ray-deep))}
[dir=rtl] .link.on{background:linear-gradient(-90deg,var(--ray),var(--ray-deep))}

.legend{display:flex;flex-wrap:wrap;gap:12px;font-size:11.5px;color:var(--bone-dim);margin-top:2px}
.legend i{display:inline-block;width:9px;height:9px;border-radius:50%;margin-inline-end:5px}

/* ---------- Attributes ---------- */
.attr{margin-bottom:11px}
.attr .al{display:flex;justify-content:space-between;font-size:12.5px;font-weight:700;margin-bottom:5px}
.attr .al span{color:var(--bone-dim)}

/* streak + activity */
.statgrid{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.stat{background:var(--ink-2);border:1px solid var(--line);border-radius:var(--radius-sm);padding:14px;text-align:center}
.stat b{display:block;font-size:22px;line-height:1.2}
.stat span{font-size:11.5px;color:var(--bone-dim);font-weight:700}
.stat .ic{display:block;width:20px;height:20px;margin:0 auto 6px;color:var(--ray)}
.stat.gold .ic{color:var(--gold)}

.minibars{display:flex;align-items:flex-end;gap:6px;height:64px;margin-top:8px}
.minibars i{flex:1;background:linear-gradient(180deg,var(--ray),var(--ray-deep));border-radius:4px 4px 0 0;
  min-height:4px;opacity:.9;transform:scaleY(0);transform-origin:bottom;transition:transform .9s var(--ease)}
.in .minibars i{transform:scaleY(1)}

/* ---------- Achievements grid ---------- */
.agrid{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.ach{
  border-radius:var(--radius);padding:16px 14px;text-align:center;
  background:linear-gradient(165deg,var(--ink-3),var(--ink-2));
  border:1px solid var(--line);position:relative;overflow:hidden;
}
.ach .ic{display:block;width:30px;height:30px;margin:0 auto 8px;color:var(--rc,var(--ray))}
.ach b{display:block;font-size:13.5px;margin-bottom:3px}
.ach p{font-size:11.5px;color:var(--bone-dim);line-height:1.5;min-height:34px}
.ach .rar{display:inline-block;margin-top:8px;font-size:10px;font-weight:800;letter-spacing:.1em;
  color:var(--rc);border:1px solid;border-radius:99px;padding:2px 9px;text-transform:uppercase}
.ach .date{display:block;margin-top:7px;font-size:10.5px;color:var(--bone-dim)}
.ach.locked{opacity:.55;filter:grayscale(.7)}
.ach .aprog{margin-top:9px}
.ach .aprog .bar{height:5px}
.ach .aprog span{font-size:10.5px;color:var(--bone-dim)}

/* ---------- Athlete card ---------- */
.acardwrap{perspective:1300px;margin-bottom:14px}
.acard{position:relative;height:315px;cursor:pointer;transform-style:preserve-3d;transition:transform .8s var(--ease)}
.acardwrap.flip .acard{transform:rotateY(180deg)}
.aface{
  position:absolute;inset:0;border-radius:22px;padding:20px;
  backface-visibility:hidden;-webkit-backface-visibility:hidden;overflow:hidden;
  background:linear-gradient(155deg,#1b232e 0%,#11151b 60%);
  border:1.5px solid var(--tc,var(--ray));
  box-shadow:0 18px 50px rgba(0,0,0,.5), inset 0 0 60px rgba(63,211,220,.05);
}
.aface.back{transform:rotateY(180deg)}
.aface::before{
  content:'';position:absolute;inset:0;opacity:.1;pointer-events:none;
  background:radial-gradient(400px 220px at 85% 0%, var(--tc,var(--ray)), transparent 70%);
}
.acard .rayart{position:absolute;inset-inline-end:-30px;bottom:-34px;width:190px;height:190px;opacity:.07;color:var(--tc,var(--ray))}
.acard .top{display:flex;justify-content:space-between;align-items:flex-start;position:relative}
.acard .tier{font-size:11px;font-weight:800;letter-spacing:.22em;color:var(--tc,var(--ray))}
.acard .lv{font-size:12px;font-weight:800;color:var(--bone-dim)}
.acard .aname{font-size:26px;font-weight:800;margin-top:12px;position:relative}
.acard .aprog-name{font-size:12.5px;color:var(--bone-dim);position:relative}
.acard .beltline{display:flex;align-items:center;gap:10px;margin-top:16px;position:relative}
.acard .beltline .beltvis{width:52px;height:14px}
.acard .beltline span{font-size:12px;font-weight:700;color:var(--bone-dim)}
.acard .xpblock{margin-top:18px;position:relative}
.acard .xpblock .xpline{margin:0 0 6px}
.acard .cardfoot{position:absolute;bottom:16px;inset-inline:20px;display:flex;justify-content:space-between;align-items:center;font-size:10px;letter-spacing:.16em;color:var(--bone-dim);font-weight:800}
.acard .back h4{font-size:11px;letter-spacing:.18em;color:var(--tc,var(--ray));font-weight:800;margin-bottom:10px}
.acard .back .bs{margin-bottom:8px}
.acard .back .bs .al{display:flex;justify-content:space-between;font-size:12px;font-weight:700;margin-bottom:4px}
.acard .back .arow{display:flex;gap:10px;margin-top:4px}
.acard .back .arow .ic{width:22px;height:22px;color:var(--gold)}
.fliphint{text-align:center;font-size:11.5px;color:var(--bone-dim);margin-top:-4px;margin-bottom:12px}

/* profile stats */
.pstats{display:grid;grid-template-columns:repeat(2,1fr);gap:12px;margin-bottom:12px}

/* ---------- Parent ---------- */
.kids{display:flex;gap:10px;margin-bottom:16px}
.kid{
  flex:1;display:flex;align-items:center;gap:10px;padding:10px 12px;border-radius:14px;
  background:var(--ink-2);border:1px solid var(--line);transition:all .3s var(--ease);
}
.kid .av{width:38px;height:38px;border-radius:50%;display:grid;place-items:center;font-weight:800;
  background:var(--ink-4);color:var(--bone-dim);flex:none}
.kid b{display:block;font-size:13.5px;line-height:1.3}
.kid span{font-size:11px;color:var(--bone-dim);font-weight:700}
.kid.active{border-color:rgba(63,211,220,.5);background:linear-gradient(165deg,rgba(63,211,220,.10),var(--ink-2))}
.kid.active .av{background:var(--ray-soft);color:var(--ray)}

.phero{display:flex;align-items:center;gap:16px}
.phero .grow{flex:1}
.phero .pname{font-size:19px;font-weight:800}
.phero .ptier{font-size:12.5px;font-weight:800;color:var(--tc,var(--ray));letter-spacing:.08em}
.phero .pbelt{display:flex;align-items:center;gap:8px;margin-top:8px;font-size:12px;color:var(--bone-dim)}
.phero .pbelt .beltvis{width:44px;height:12px}

.mgrid{display:grid;grid-template-columns:1fr 1fr;gap:12px}

/* radar */
.radarwrap{display:flex;justify-content:center;padding:6px 0 2px}
.radar poly, .radar polygon{transition:all 1s var(--ease)}

/* trend */
.trend svg{width:100%;height:80px;display:block}
.trend .axis{stroke:var(--line-strong);stroke-width:1}
.trend .line{fill:none;stroke:var(--ray);stroke-width:2.5;stroke-linecap:round;stroke-linejoin:round;
  filter:drop-shadow(0 0 6px rgba(63,211,220,.45))}
.trend .area{fill:url(#trendfill);opacity:.5}

/* updates feed */
.feed li{display:flex;gap:12px;align-items:flex-start;padding:11px 0;border-bottom:1px solid var(--line)}
.feed li:last-child{border-bottom:0}
.feed .ic{width:20px;height:20px;color:var(--ray);margin-top:2px}
.feed p{font-size:13.5px;line-height:1.5}
.feed span{font-size:11px;color:var(--bone-dim)}

/* schedule */
.day{display:flex;gap:14px;align-items:center;padding:13px 0;border-bottom:1px solid var(--line)}
.day:last-child{border-bottom:0}
.day .dchip{width:74px;flex:none;text-align:center;background:var(--ink-2);border:1px solid var(--line);
  border-radius:12px;padding:8px 4px}
.day .dchip b{display:block;font-size:12.5px}
.day .dchip span{font-size:10.5px;color:var(--ray);font-weight:800}
.day .grow{flex:1}
.day .grow b{font-size:14px;display:block}
.day .grow span{font-size:12px;color:var(--bone-dim)}
.attdots{display:flex;gap:6px;margin-top:8px}
.attdots i{width:10px;height:10px;border-radius:50%;background:var(--ink-4)}
.attdots i.on{background:var(--green)}
.attdots i.miss{background:var(--red);opacity:.7}

/* improvement callout */
.improve{display:flex;gap:12px;align-items:flex-start}
.improve .ic{color:var(--gold);width:22px;height:22px;margin-top:2px}

/* level-up toast (motion demo) */
.toast{
  position:fixed;bottom:96px;left:50%;transform:translate(-50%,20px);opacity:0;z-index:60;
  background:linear-gradient(165deg,#1d2733,#141922);border:1px solid rgba(212,169,78,.5);
  border-radius:16px;padding:13px 20px;display:flex;align-items:center;gap:11px;
  box-shadow:0 18px 50px rgba(0,0,0,.6);transition:all .5s var(--ease);pointer-events:none;
  font-size:13.5px;font-weight:700;white-space:nowrap;
}
.toast.show{opacity:1;transform:translate(-50%,0)}
.toast .ic{color:var(--gold);width:22px;height:22px}

@media (min-width:560px){
  .phone{margin:26px 0;min-height:calc(100vh - 52px);border:1px solid var(--line);
    border-radius:34px;overflow:hidden;box-shadow:var(--shadow)}
  .appbar{border-radius:34px 34px 0 0}
}

/* ---------- real brand artwork placements ---------- */
.appbar .mark{width:34px;height:30px}
.roles .mark-big{width:min(300px,74vw);height:auto;aspect-ratio:717/334;margin:0 auto 14px}
.treemark{width:34px;height:30px;flex:none}
.progmark{width:30px;height:26px;flex:none}
.acard .rayart{inset-inline-end:-26px;bottom:-20px;width:180px;height:160px;opacity:.08}
.acard .rayart img{filter:none}

/* ============================================================
   Sign-in / auth screens
   ============================================================ */
.authwrap{min-height:100vh;display:flex;flex-direction:column;justify-content:center;
  padding:34px 22px 26px;
  background:radial-gradient(800px 460px at 50% -6%, rgba(63,211,220,.10), transparent 65%), var(--ink)}
.authcard{width:100%;max-width:420px;margin:0 auto}
.authlogo{display:block;width:min(280px,72vw);height:auto;aspect-ratio:717/334;margin:0 auto 26px}
.authcard h1{font-size:25px;font-weight:800;text-align:center;letter-spacing:-.01em}
.authsub{text-align:center;color:var(--bone-dim);font-size:14px;margin:8px 0 26px}
.authcard label{display:block;font-size:11.5px;font-weight:800;letter-spacing:.12em;
  text-transform:uppercase;color:var(--bone-dim);margin:16px 0 7px}
.authcard input{width:100%;background:var(--ink-2);border:1px solid var(--line-strong);
  border-radius:13px;padding:14px 15px;color:var(--bone);font:inherit;font-size:16px;
  transition:border-color .25s var(--ease)}
.authcard input:focus{outline:none;border-color:var(--ray);background:var(--ink-3)}
.pwrap{position:relative}
.pwrap input{padding-inline-end:48px}
.peye{position:absolute;inset-inline-end:6px;top:50%;transform:translateY(-50%);
  width:38px;height:38px;display:grid;place-items:center;color:var(--bone-dim);border-radius:9px}
.peye svg{width:21px;height:21px}
.peye.on{color:var(--ray)}
.authbtn{width:100%;margin-top:24px;padding:15px;border-radius:13px;font-weight:800;font-size:15.5px;
  background:linear-gradient(120deg,var(--ray-deep),var(--ray));color:#062125;
  box-shadow:0 10px 30px rgba(63,211,220,.26);transition:all .3s var(--ease)}
.authbtn:hover:not(:disabled){transform:translateY(-1px);box-shadow:0 14px 36px rgba(63,211,220,.36)}
.authbtn:disabled{opacity:.6;cursor:default}
.autherr{margin-top:16px;background:rgba(224,96,96,.12);border:1px solid rgba(224,96,96,.4);
  color:#f3bcbc;border-radius:11px;padding:11px 14px;font-size:13.5px;line-height:1.6}
.authlink{display:block;margin:18px auto 0;color:var(--bone-dim);font-size:13px;font-weight:700}
.authlink:hover{color:var(--ray)}
.authdemo{margin-top:26px;padding-top:22px;border-top:1px solid var(--line);text-align:center}
.authghost{display:inline-block;padding:11px 22px;border-radius:12px;font-size:13.5px;font-weight:800;
  border:1px solid var(--line-strong);color:var(--bone-dim);transition:all .3s var(--ease)}
.authghost:hover{color:var(--ray);border-color:rgba(63,211,220,.45)}
.authfoot{text-align:center;margin-top:26px}
.authlang{font-size:13px;font-weight:800;color:var(--bone-dim);padding:8px 18px;
  border:1px solid var(--line);border-radius:10px}
.authlang:hover{color:var(--ray);border-color:rgba(63,211,220,.4)}

/* update banner */
.updbar{position:fixed;left:0;right:0;bottom:0;z-index:80;
  background:linear-gradient(165deg,#1d2733,#141922);border-top:1px solid rgba(212,169,78,.45);
  padding:14px 18px calc(14px + env(safe-area-inset-bottom));
  display:flex;align-items:center;gap:13px;box-shadow:0 -12px 40px rgba(0,0,0,.5)}
.updbar .ic{color:var(--gold);width:24px;height:24px;flex:none}
.updbar .grow{flex:1;min-width:0}
.updbar b{display:block;font-size:14px}
.updbar span{display:block;font-size:12px;color:var(--bone-dim)}
.updbar a.go{background:linear-gradient(120deg,#a8843a,var(--gold));color:#1a1204;font-weight:800;
  font-size:13px;padding:9px 16px;border-radius:10px;white-space:nowrap}
.updbar button.later{color:var(--bone-dim);font-size:12.5px;font-weight:700;padding:6px}

/* ============================================================
   Staff (coach + admin) UI
   ============================================================ */
.minibtn{font-size:12.5px;font-weight:800;padding:8px 14px;border-radius:10px;
  background:var(--ray-soft);color:var(--ray);border:1px solid rgba(63,211,220,.3);white-space:nowrap}
.minibtn:hover{background:rgba(63,211,220,.2)}
.ghostbtn{font-size:13.5px;font-weight:800;padding:11px 18px;border-radius:12px;
  border:1px solid var(--line-strong);color:var(--bone-dim);transition:all .3s var(--ease)}
.ghostbtn:hover{color:var(--ray);border-color:rgba(63,211,220,.45)}
.ghostbtn.wide{display:block;width:100%;margin-top:10px;text-align:center}
.ghostbtn.gold{color:var(--gold);border-color:rgba(212,169,78,.4)}
.ghostbtn.danger{color:var(--red);border-color:rgba(224,96,96,.35)}
.ghostbtn.danger:hover{color:var(--red);border-color:rgba(224,96,96,.6)}
.searchbox{width:100%;background:var(--ink-2);border:1px solid var(--line);border-radius:12px;
  padding:12px 15px;color:var(--bone);font:inherit;font-size:14.5px;margin-bottom:14px}
.searchbox:focus{outline:none;border-color:var(--ray)}
.pav{width:36px;height:36px;border-radius:50%;flex:none;display:grid;place-items:center;
  background:var(--ink-4);color:var(--bone-dim);font-weight:800;font-size:15px}
.small{font-size:12px}

/* bottom sheet */
.sheetwrap{position:fixed;inset:0;z-index:90;display:flex;align-items:flex-end;justify-content:center}
.sheetbg{position:absolute;inset:0;background:rgba(4,6,9,.72);opacity:0;transition:opacity .3s var(--ease)}
.sheetwrap.in .sheetbg{opacity:1}
.sheet{position:relative;width:100%;max-width:520px;max-height:88vh;overflow-y:auto;
  background:linear-gradient(180deg,var(--ink-3),var(--ink-2));
  border:1px solid var(--line-strong);border-bottom:0;border-radius:22px 22px 0 0;
  transform:translateY(100%);transition:transform .36s var(--ease);
  padding-bottom:calc(22px + env(safe-area-inset-bottom))}
.sheetwrap.in .sheet{transform:none}
.sheethead{position:sticky;top:0;z-index:2;display:flex;align-items:center;justify-content:space-between;
  padding:18px 20px 14px;background:var(--ink-3);border-bottom:1px solid var(--line)}
.sheethead b{font-size:17px;font-weight:800}
.sheetx{font-size:26px;line-height:1;color:var(--bone-dim);width:34px;height:34px;border-radius:9px}
.sheetx:hover{color:var(--bone)}
.sheetbody{padding:18px 20px 6px}
.sheetbody label{display:block;font-size:11.5px;font-weight:800;letter-spacing:.1em;text-transform:uppercase;
  color:var(--bone-dim);margin:15px 0 6px}
.sheetbody input,.sheetbody select,.sheetbody textarea{width:100%;background:var(--ink);
  border:1px solid var(--line-strong);border-radius:12px;padding:12px 14px;color:var(--bone);
  font:inherit;font-size:15.5px;margin-bottom:2px}
.sheetbody textarea{margin-bottom:10px;resize:vertical;line-height:1.6}
.sheetbody input:focus,.sheetbody select:focus,.sheetbody textarea:focus{outline:none;border-color:var(--ray)}
.sheetbody select{appearance:none;background-image:linear-gradient(45deg,transparent 50%,var(--bone-dim) 50%),
  linear-gradient(135deg,var(--bone-dim) 50%,transparent 50%);
  background-position:calc(100% - 18px) 50%,calc(100% - 13px) 50%;background-size:5px 5px,5px 5px;
  background-repeat:no-repeat}
[dir=rtl] .sheetbody select{background-position:18px 50%,23px 50%}

/* attendance roster */
.rlist{margin:8px 0 4px}
.rrow{display:flex;align-items:center;gap:12px;padding:11px 0;border-bottom:1px solid var(--line)}
.rrow:last-child{border-bottom:0}
.rname{flex:1;min-width:0}
.rname b{display:block;font-size:14.5px}
.rname span{font-size:11.5px;color:var(--bone-dim)}
.rbtns{display:flex;gap:5px;flex:none}
.att{font-size:11.5px;font-weight:800;padding:8px 11px;border-radius:9px;
  border:1px solid var(--line-strong);color:var(--bone-dim)}
.att.p.on{background:rgba(87,184,119,.18);color:var(--green);border-color:rgba(87,184,119,.5)}
.att.l.on{background:var(--gold-soft);color:var(--gold);border-color:rgba(212,169,78,.5)}
.att.a.on{background:rgba(224,96,96,.15);color:var(--red);border-color:rgba(224,96,96,.45)}

/* trainee summary in sheet */
.tsum{display:flex;align-items:center;gap:14px;padding:14px;border-radius:14px;background:var(--ink);
  border:1px solid var(--line);margin-bottom:14px}
.tsum b{display:block;font-size:15px}
.tsum span{font-size:12.5px;color:var(--bone-dim)}
.actrow{display:flex;gap:8px;flex-wrap:wrap}
.actrow .ghostbtn{flex:1;text-align:center;padding:11px 10px;font-size:12.5px}

/* skill grid for coaches */
.skgrid{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.skbtn{display:flex;flex-direction:column;align-items:flex-start;gap:3px;padding:12px 13px;
  border-radius:12px;border:1.5px solid var(--line-strong);background:var(--ink);text-align:start;
  transition:all .28s var(--ease)}
.skbtn span{font-size:13px;font-weight:700;line-height:1.3}
.skbtn i{font-size:10.5px;font-weight:800;letter-spacing:.08em;text-transform:uppercase;font-style:normal;
  color:var(--bone-dim)}
.skbtn.s-locked{opacity:.55}
.skbtn.s-inprogress{border-color:var(--ray);}
.skbtn.s-inprogress i{color:var(--ray)}
.skbtn.s-completed{border-color:var(--ray);background:rgba(63,211,220,.09)}
.skbtn.s-completed i{color:var(--ray)}
.skbtn.s-mastered{border-color:var(--gold);background:var(--gold-soft)}
.skbtn.s-mastered i{color:var(--gold)}
.skbtn:disabled{opacity:.5}

/* achievement picker */
.achpick{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.apick{display:flex;flex-direction:column;align-items:center;gap:7px;padding:16px 10px;border-radius:14px;
  border:1px solid var(--line-strong);background:var(--ink);color:var(--bone);font-size:12.5px;font-weight:700}
.apick .ic{width:26px;height:26px;color:var(--ray)}
.apick.has{opacity:.4}
.apick:not(.has):hover{border-color:var(--ray)}

.toast.bad{border-color:rgba(224,96,96,.5)}
.toast.bad .ic{color:var(--red)}

/* boot / splash while data loads */
.bootwrap{min-height:100vh;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:26px;padding:30px}
.bootlogo{display:block;width:min(260px,68vw);height:auto;aspect-ratio:717/334;opacity:.95}
.bootbar{width:150px;height:3px;background:var(--ink-4);border-radius:99px;overflow:hidden}
.bootbar i{display:block;height:100%;width:40%;border-radius:99px;
  background:linear-gradient(90deg,var(--ray-deep),var(--ray));animation:bootslide 1.1s var(--ease) infinite}
@keyframes bootslide{0%{transform:translateX(-110%)}100%{transform:translateX(320%)}}
.chip.rolechip{background:var(--gold-soft);color:var(--gold);border-color:rgba(212,169,78,.32)}
.authghost.wide{display:block;width:100%;margin-top:12px;text-align:center}

/* setup-not-finished hint on the sign-in screen */
.setuphint{background:var(--gold-soft);border:1px solid rgba(212,169,78,.4);border-radius:13px;
  padding:15px 16px;margin-bottom:8px}
.setuphint b{display:block;font-size:14px;color:var(--gold);margin-bottom:5px}
.setuphint p{font-size:13px;color:var(--bone-dim);line-height:1.6;margin-bottom:11px}
.setuphint a{display:inline-block;background:linear-gradient(120deg,#a8843a,var(--gold));color:#1a1204;
  font-weight:800;font-size:13px;padding:9px 16px;border-radius:10px}
