/* Spectrum (Adobe) design language, with the app's palette only.
   Spectrum: calm surfaces, pill buttons, 2px focus ring with a gap, a tray for sheets, a 4px grid.
   Icons: Material Symbols only (fonts.google.com/icons). The field is the lightest grey (pale-violet); the lesson's name is the darkest grey (light-grey). No text where a picture or a number will do. */
:root{
  --indigo:#3035D0;      /* 11% */
  --blue:#567BFB;        /* 28% */
  --blue-2:#6DA5FF;      /* 10% */
  --white:#FAF5FB;       /* 17% */
  --pale-violet:#ECE9EE; /* 10% */
  --light-grey:#C2C0CB;  /* 4% */
  --rose:#FC2B55;        /* 10% */
  --teal:#15C29F;        /* 10% */

  /* the roles, as Spectrum names them */
  --field:var(--pale-violet);
  --ink:var(--indigo);
  --accent:var(--indigo);         --accent-ink:var(--white);
  --positive:var(--teal);         --negative:var(--rose);        --notice:var(--blue-2);
  --paper:var(--white);
  --focus:var(--indigo);

  --ui:'Adobe Clean','Assistant','Source Sans 3',system-ui,-apple-system,'Segoe UI',Arial,sans-serif;
  --r-s:8px;--r-m:16px;--r-l:24px;--r-pill:999px;
  --s1:4px;--s2:8px;--s3:12px;--s4:16px;--s5:24px;--s6:32px;
  color-scheme:light;
}
[hidden]{display:none!important}
*{box-sizing:border-box}
html,body{height:100%}
body{margin:0;background:var(--field);color:var(--ink);font-family:var(--ui);font-size:16px;line-height:1.4;direction:rtl;-webkit-tap-highlight-color:transparent}
button,input{font:inherit;color:inherit}
button{cursor:pointer}
:focus-visible{outline:2px solid var(--indigo);outline-offset:2px}

/* Material Symbols */
.ms{font-family:'Material Symbols Rounded';font-weight:normal;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;direction:ltr;
  -webkit-font-feature-settings:'liga';font-feature-settings:'liga';-webkit-font-smoothing:antialiased;font-variation-settings:'FILL' 0,'wght' 500,'GRAD' 0,'opsz' 24;flex:none}
.ms.fill{font-variation-settings:'FILL' 1,'wght' 500,'GRAD' 0,'opsz' 24}

/* buttons: accent (filled) / secondary (outline) / negative */
.btn{min-height:48px;padding:0 var(--s5);border-radius:var(--r-pill);border:2px solid var(--accent);background:var(--accent);color:var(--accent-ink);
  font-weight:800;font-size:17px;display:inline-flex;align-items:center;justify-content:center;gap:var(--s2);transition:filter .12s}
.btn:hover{filter:brightness(1.08)}
.btn:active{filter:brightness(.92)}
.btn.ghost{background:transparent;border-color:var(--indigo);color:var(--indigo)}
.btn.danger{background:transparent;border-color:var(--rose);color:var(--rose)}
.btn:disabled{opacity:.45;pointer-events:none}

/* round icon buttons */
.round{width:44px;height:44px;border-radius:50%;border:0;background:var(--indigo);color:var(--white);padding:0;display:inline-flex;align-items:center;justify-content:center;box-shadow:0 2px 8px rgba(48,53,208,.3);flex:none}
.round:disabled{opacity:.35}
.round.neg{background:var(--rose)}
.round.soft{background:var(--white);color:var(--indigo)}

/* ---- the balls ---- */
body.balls{overflow:hidden;overscroll-behavior:none;-webkit-user-select:none;user-select:none}
#cv{position:fixed;inset:0;width:100%;height:100%;display:block;touch-action:none}
#undo,#burger2{position:fixed;z-index:2;top:calc(12px + env(safe-area-inset-top,0px))}
#undo{left:50%;transform:translateX(-50%)}
#burger2{right:max(16px,env(safe-area-inset-right,0px))}
#net{position:fixed;z-index:6;bottom:calc(96px + env(safe-area-inset-bottom,0px));left:50%;transform:translateX(-50%);padding:var(--s2) var(--s4);border-radius:var(--r-pill);
  background:var(--rose);color:var(--white);font-weight:700;font-size:14.5px;white-space:nowrap;display:flex;align-items:center;gap:var(--s2)}
#empty{position:fixed;inset:0;z-index:1;display:flex;align-items:center;justify-content:center;text-align:center;padding:24px;color:var(--indigo);font-size:18px}

/* the way into the class: a ball that stays where it is (the other balls pile around it). A tap opens the lesson */
#fab{position:fixed;z-index:3;border:0;border-radius:50%;background:var(--indigo);color:var(--white);padding:0;display:flex;align-items:center;justify-content:center;box-shadow:0 6px 16px rgba(48,53,208,.4)}
#fab .ms{font-size:34px}
#fab:active{transform:scale(.94)}

/* the lesson: a full screen of balls. One row on top: the close, three numbers, the icons */
#panel{position:fixed;z-index:5;inset:0;display:flex;flex-direction:column;background:var(--paper);color:var(--ink);
  transform:translateY(105%);transition:transform .28s cubic-bezier(.2,.8,.2,1);visibility:hidden}
#panel.open{transform:translateY(0);visibility:visible}
#tab{flex:none;display:flex;align-items:center;gap:var(--s3);touch-action:none;padding:calc(12px + env(safe-area-inset-top,0px)) max(16px,env(safe-area-inset-right,0px)) var(--s3) max(16px,env(safe-area-inset-left,0px))}
#sum{flex:1;display:flex;gap:var(--s5);justify-content:center;align-items:baseline;font-weight:800;font-size:30px;line-height:1}
#sum .ok{color:var(--teal)}#sum .bad{color:var(--rose)}#sum .none{color:var(--indigo)}
#acts{display:flex;gap:var(--s2);align-items:center}
#acts .chip{min-height:44px;padding:0 var(--s4);border-radius:var(--r-pill);border:2px solid var(--indigo);background:transparent;color:var(--indigo);font-weight:800;font-size:15px}
#acts .chip.on{background:var(--indigo);color:var(--white)}
#body{flex:1;overflow-y:auto;-webkit-overflow-scrolling:touch;padding:var(--s2) max(12px,env(safe-area-inset-right,0px)) calc(24px + env(safe-area-inset-bottom,0px));display:flex;justify-content:center}
#gal{display:grid;grid-template-columns:repeat(auto-fill,minmax(72px,1fr));gap:12px 10px;width:100%;max-width:640px;align-content:start}
#gal button{position:relative;border:0;background:none;padding:0;display:block;min-width:0;aspect-ratio:1}
#gal img{width:100%;height:100%;border-radius:50%;object-fit:cover;border:4px solid var(--light-grey);background:var(--pale-violet);display:block}
#gal .ok img{border-color:var(--teal)}
#gal .bad img{border-color:var(--rose);filter:none}
#gal .late img{border-color:var(--blue-2)}
#gal small{position:absolute;bottom:0;inset-inline-end:0;width:24px;height:24px;border-radius:50%;background:var(--blue-2);color:var(--indigo);display:flex;align-items:center;justify-content:center}
#gal small .ms{font-size:18px}

/* ---- login + admin: white cards on the light grey ---- */
.page{min-height:100%;display:flex;flex-direction:column;align-items:center;gap:var(--s4);
  padding:calc(36px + env(safe-area-inset-top,0px)) max(16px,env(safe-area-inset-right,0px)) calc(28px + env(safe-area-inset-bottom,0px)) max(16px,env(safe-area-inset-left,0px))}
.page h1{margin:0;font-size:30px;font-weight:800;display:flex;align-items:center;gap:var(--s3);color:var(--indigo)}
.page h1 .ms{color:var(--blue);font-size:34px}
.page > p{margin:0;color:#5b5ea8;text-align:center;max-width:340px}
.card{width:100%;max-width:380px;background:var(--paper);color:var(--ink);border-radius:var(--r-m);padding:var(--s5);display:flex;flex-direction:column;gap:var(--s3);box-shadow:0 2px 12px rgba(48,53,208,.14)}
.card h2{margin:0;font-size:18px;font-weight:800;display:flex;align-items:center;gap:var(--s2)}
.card h2 .ms{color:var(--blue)}
.card p{margin:0;color:#4b4fa6;font-size:15px}
.card .btn{width:100%}
#code{min-height:54px;width:100%;border:2px solid var(--light-grey);border-radius:var(--r-s);background:var(--white);color:var(--indigo);text-align:center;direction:ltr;font-size:24px;font-weight:700;letter-spacing:.12em;text-transform:uppercase}
#code:focus{border-color:var(--blue);outline:none}
#msg{margin:0;font-weight:700;text-align:center}
#msg:not(:empty){background:var(--rose);color:var(--white);padding:var(--s2) var(--s4);border-radius:var(--r-pill)}
.row{display:flex;gap:var(--s2);flex-wrap:wrap}
.row .btn{flex:1;width:auto;min-height:44px;font-size:16px;padding:0 var(--s3)}
.who{display:flex;align-items:baseline;justify-content:space-between;gap:var(--s2)}
.who small{color:#4b4fa6;font-size:14px}
.codebox{direction:ltr;text-align:center;font-size:30px;font-weight:700;letter-spacing:.1em;padding:var(--s3);border-radius:var(--r-s);background:var(--pale-violet);color:var(--indigo);border:2px solid var(--teal);-webkit-user-select:all;user-select:all}
a.back{color:var(--indigo);font-weight:700;text-decoration:none;min-height:44px;display:inline-flex;align-items:center;gap:var(--s2)}

/* ---- desktop: photos | bar | table ---- */
body.desk{overflow:hidden;display:flex;flex-direction:column;height:100dvh}
#bar{flex:none;display:flex;align-items:center;gap:var(--s5);padding:var(--s3) var(--s5);background:var(--paper);box-shadow:0 1px 0 rgba(48,53,208,.12)}
#courses{display:flex;gap:var(--s2);align-items:center;min-width:0}
#courses .title{font-weight:800;font-size:20px;color:var(--indigo)}
.chip{min-height:40px;padding:0 var(--s4);border-radius:var(--r-pill);border:2px solid var(--indigo);background:transparent;color:var(--indigo);font-weight:800;font-size:15px}
.chip.on{background:var(--indigo);color:var(--white)}
#bar #sum{flex:1;display:flex;gap:var(--s5);justify-content:center;align-items:baseline;font-weight:800;font-size:30px;line-height:1}
#sum .ok{color:var(--teal)}#sum .bad{color:var(--rose)}#sum .none{color:var(--indigo)}
#tools{display:flex;gap:var(--s2)}
#tools a.round{text-decoration:none}
#split{flex:1;min-height:0;display:flex;padding:var(--s4);gap:0}
#photos{flex:none;width:var(--pw,34vw);overflow-y:auto;padding:var(--s2)}
body.desk #gal{display:grid;grid-template-columns:repeat(auto-fill,minmax(84px,1fr));gap:14px 12px;max-width:none}
body.desk #gal button{position:relative;border:0;background:none;padding:0;aspect-ratio:1;display:block;border-radius:50%;transition:transform .12s}
body.desk #gal button:hover,body.desk #gal button.hot{transform:scale(1.06)}
body.desk #gal img{width:100%;height:100%;border-radius:50%;object-fit:cover;border:4px solid var(--light-grey);background:var(--pale-violet);display:block;box-shadow:0 2px 8px rgba(48,53,208,.18)}
body.desk #gal .ok img{border-color:var(--teal)}
body.desk #gal .bad img{border-color:var(--rose);filter:none}
body.desk #gal .late img{border-color:var(--blue-2)}
body.desk #gal .hot img{box-shadow:0 0 0 3px var(--indigo)}
#bar2{flex:none;width:16px;margin:0 var(--s2);border-radius:var(--r-pill);background:var(--pale-violet);box-shadow:inset 0 0 0 2px var(--light-grey);cursor:col-resize;display:flex;align-items:center;justify-content:center;color:var(--indigo);touch-action:none}
#bar2:hover,#bar2.on{background:var(--indigo);box-shadow:none;color:var(--white)}
#bar2 .ms{font-size:20px}
#tbl{flex:1;min-width:0;overflow:auto;background:var(--paper);border-radius:var(--r-m);box-shadow:0 2px 12px rgba(48,53,208,.14)}
table{border-collapse:separate;border-spacing:0;width:100%}
th,td{padding:6px 10px;text-align:center;white-space:nowrap;border-bottom:1px solid var(--pale-violet)}
thead th{position:sticky;top:0;background:var(--paper);z-index:2;padding:var(--s2) 10px}
th.who{position:sticky;right:0;background:var(--paper);z-index:1;text-align:start;font-weight:700;color:var(--indigo);display:table-cell}
thead th:first-child{right:0;z-index:3}
th.who img{width:32px;height:32px;border-radius:50%;object-fit:cover;vertical-align:middle;margin-inline-end:var(--s2);border:2px solid var(--light-grey)}
.n{font-weight:800;font-size:16px;min-width:36px}
.n.bad,.ms.bad{color:var(--rose)}.n.late,.ms.late{color:#2f6fe0}.ms.ok{color:var(--teal)}
tbody tr:hover td,tbody tr:hover th.who{background:var(--pale-violet)}
.dh{border:0;background:transparent;color:var(--indigo);font-weight:800;font-size:15px;padding:4px 10px;border-radius:var(--r-pill)}
.dh.on{background:var(--indigo);color:var(--white)}
td.cell{cursor:pointer;min-width:52px}
td.cell.cur{background:rgba(48,53,208,.07)}
td.cell:hover{background:var(--pale-violet)}
.err{padding:var(--s5);color:var(--rose);font-weight:700}

.mk{font-size:20px;font-weight:800;line-height:1}.mk.ok{color:var(--teal)}.mk.bad{color:var(--rose)}.mk.late{color:#2f6fe0}
thead th.n{font-size:18px;font-weight:800}

/* the informative table: rate, sortable heads, a foot with the day's count */
.n.r{min-width:52px}.n.r.ok{color:#0e8a70}.n.r.mid{color:var(--indigo)}.n.r.bad{color:var(--rose)}
.sort{border:0;background:transparent;color:inherit;font-weight:800;font-size:18px;padding:2px 8px;border-radius:var(--r-pill);display:inline-flex;align-items:center}
.sort:hover{background:var(--pale-violet)}.sort.on{background:var(--indigo);color:var(--white)}
th.n.bad .sort{color:var(--rose)}th.n.late .sort{color:#2f6fe0}th.n.r .sort{color:var(--indigo)}
th.n .sort.on{color:var(--white)}
tfoot td,tfoot th{position:sticky;bottom:0;background:var(--paper);z-index:2;border-top:2px solid var(--pale-violet);border-bottom:0}
tfoot td b.ok{color:var(--teal);font-size:17px}.of{color:#8a8cc4;font-size:12px;font-weight:700}

/* the calendar: a day off is a grey column, nothing to press */
th.off,td.off{background:rgba(194,192,203,.45)}
th.off .dh{color:#8a8aa0;cursor:default}
.sems{display:flex;gap:var(--s2);margin-inline-end:var(--s3)}

/* the phone's computer icon: 6 digits for two minutes */
#pcbtn{position:fixed;z-index:2;top:calc(12px + env(safe-area-inset-top,0px));left:max(16px,env(safe-area-inset-left,0px))}
#pc{position:fixed;inset:0;z-index:7;background:rgba(48,53,208,.55);display:flex;align-items:center;justify-content:center;padding:var(--s5)}
#pcbox{position:relative;width:100%;max-width:340px;background:var(--paper);border-radius:var(--r-l);padding:var(--s6) var(--s5) var(--s5);display:flex;flex-direction:column;align-items:center;gap:var(--s4);box-shadow:0 8px 32px rgba(48,53,208,.35)}
#pcx{position:absolute;top:var(--s3);inset-inline-start:var(--s3);width:36px;height:36px}
#pcx .ms{font-size:20px}
#pcnum{font-size:52px;font-weight:800;letter-spacing:.08em;color:var(--indigo);font-variant-numeric:tabular-nums;margin-top:var(--s3)}
#pcbar{width:100%;height:6px;border-radius:3px;background:var(--pale-violet);overflow:hidden}
#pcbar i{display:block;height:100%;width:100%;background:var(--blue);transform-origin:left center}
#pcbar.run i{animation:drain var(--sec,120s) linear forwards}
@keyframes drain{to{transform:scaleX(0)}}

/* the login page on a computer */
#pcform input{min-height:60px;width:100%;border:2px solid var(--light-grey);border-radius:var(--r-s);background:var(--white);color:var(--indigo);text-align:center;direction:ltr;font-size:30px;font-weight:800;letter-spacing:.3em}
#pcform input:focus{border-color:var(--blue);outline:none}

/* the camera: it opens inside the big ball */
#cam{position:fixed;inset:0;z-index:4;pointer-events:none}
#cam > *{pointer-events:auto}
#camring{position:fixed;border-radius:50%;overflow:hidden;background:var(--indigo);box-shadow:0 0 0 6px var(--white),0 8px 28px rgba(48,53,208,.4)}
#camring video,#camring img{width:100%;height:100%;object-fit:cover;display:block}
#camring video.mirror{transform:scaleX(-1)}
.camact{position:fixed;left:0;right:0;display:flex;justify-content:center;align-items:center;gap:var(--s5)}
.round.big{width:64px;height:64px}
.round.big .ms{font-size:30px}
.round.ok{background:var(--teal)}
#toast{position:fixed;z-index:9;left:50%;bottom:calc(110px + env(safe-area-inset-bottom,0px));transform:translateX(-50%);background:var(--rose);color:var(--white);padding:var(--s2) var(--s4);border-radius:var(--r-pill);font-weight:700;font-size:15px;white-space:nowrap}

/* the admin: read only, a day or a lesson */
body.ro td.cell{cursor:default}body.ro #gal button{cursor:default}
body.ro td.cell:hover{background:transparent}
#courses select{min-height:40px;border-radius:var(--r-pill);border:2px solid var(--indigo);background:var(--white);color:var(--indigo);font-weight:800;font-size:15px;padding:0 var(--s4);max-width:320px}
body.desk #gal .part img{border-color:var(--teal) var(--rose) var(--rose) var(--teal)}
.ms.part{color:var(--indigo);font-size:22px}

/* the admin page: a table, not cards */
.page.wide{max-width:980px;margin:0 auto}
#list{width:100%}
.atable{width:100%;border-collapse:separate;border-spacing:0;background:var(--paper);color:var(--ink);border-radius:var(--r-m);overflow:hidden;box-shadow:0 2px 12px rgba(48,53,208,.14)}
.atable th,.atable td{padding:10px 14px;text-align:start;border-bottom:1px solid var(--pale-violet);vertical-align:middle}
.atable thead th{background:var(--paper);font-size:14px;color:#5b5ea8;font-weight:700;position:sticky;top:0}
.atable tbody tr:last-child th,.atable tbody tr:last-child td{border-bottom:0}
.atable tbody tr:hover{background:var(--pale-violet)}
.atable .nm{font-weight:800;white-space:nowrap}.atable .nm .ms{vertical-align:middle;margin-inline-end:var(--s2);color:var(--blue)}
.atable .les{font-size:13.5px;color:#4b4fa6;min-width:200px}
.atable .dev{font-weight:800;text-align:center}
.atable .cd{white-space:nowrap}
.atable .code{font-weight:800;font-size:18px;letter-spacing:.06em;color:var(--indigo);margin-inline-end:var(--s2)}
.atable .until{color:#5b5ea8;font-weight:700}
.atable .act{white-space:nowrap;text-align:end}
.round.sm{width:36px;height:36px}.round.sm .ms{font-size:20px}
.atable .act .round+.round{margin-inline-start:var(--s2)}

.dh small{display:block;font-size:10.5px;font-weight:700;opacity:.75;line-height:1}
.dh.on small{opacity:.9}

/* the admin's right-click menu and the flags */
#ctx{position:fixed;z-index:8;min-width:210px;background:var(--paper);color:var(--ink);border-radius:var(--r-m);box-shadow:0 8px 28px rgba(48,53,208,.35);padding:var(--s2);display:flex;flex-direction:column;gap:2px}
#ctx .ctxh{font-weight:800;padding:var(--s2) var(--s3);color:#5b5ea8;font-size:14px;border-bottom:1px solid var(--pale-violet);margin-bottom:2px}
#ctx button[data-flag]{display:flex;align-items:center;gap:var(--s3);border:0;background:transparent;color:var(--ink);font-weight:700;font-size:15px;padding:var(--s2) var(--s3);border-radius:var(--r-s);text-align:start}
#ctx button[data-flag]:hover{background:var(--pale-violet)}
#ctx button.on{background:var(--indigo);color:var(--white)}
#ctx .clr{color:var(--rose)!important}
#ctx .ctxn{display:flex;gap:var(--s2);align-items:center;padding:var(--s2) var(--s3)}
#ctx .ctxn input{flex:1;min-height:36px;border:2px solid var(--light-grey);border-radius:var(--r-s);padding:0 var(--s2);font:inherit;color:var(--indigo)}
#ctx .ctxn input:focus{border-color:var(--blue);outline:none}
body.desk #gal em.flag{position:absolute;top:-2px;inset-inline-end:-2px;width:26px;height:26px;border-radius:50%;background:var(--indigo);color:var(--white);display:flex;align-items:center;justify-content:center;font-style:normal}
body.desk #gal em.flag .ms{font-size:16px}
.flagi{font-size:18px;color:var(--indigo);vertical-align:middle;margin-inline-start:6px}

/* the students table */
.addrow{display:flex;gap:var(--s2);align-items:center;margin-bottom:var(--s3)}
.addrow input{flex:1;min-height:44px;border:2px solid var(--light-grey);border-radius:var(--r-pill);background:var(--white);padding:0 var(--s4);font:inherit;color:var(--indigo)}
.addrow input:focus{border-color:var(--blue);outline:none}
.stable select,.addrow select{min-height:40px;border-radius:var(--r-pill);border:2px solid var(--light-grey);background:var(--white);color:var(--indigo);font:inherit;font-weight:700;padding:0 var(--s3)}
.stable .in{width:100%;min-height:40px;border:2px solid transparent;border-radius:var(--r-s);background:transparent;padding:0 var(--s2);font:inherit;color:var(--indigo);font-weight:700}
.stable .in:hover{border-color:var(--pale-violet)}.stable .in:focus{border-color:var(--blue);background:var(--white);outline:none}
.stable td.ph{width:56px}.stable td.ph img{width:40px;height:40px;border-radius:50%;object-fit:cover;display:block}
.stable td.ph .ms{width:40px;height:40px;border-radius:50%;background:var(--pale-violet);color:var(--indigo);display:flex;align-items:center;justify-content:center}
.stable .saved{color:var(--teal);margin-inline-end:var(--s2);display:inline-block;min-width:24px}

/* one student */
#who{display:flex;flex-direction:column;align-items:center;gap:var(--s3)}
.sphoto img,.sphoto .ms{width:120px;height:120px;border-radius:50%;object-fit:cover;box-shadow:0 4px 18px rgba(48,53,208,.25);border:4px solid var(--white)}
.sphoto .ms{display:flex;align-items:center;justify-content:center;background:var(--pale-violet);color:var(--indigo);font-size:56px}
#who h1{margin:0}.snote{margin:0;color:#4b4fa6;font-weight:700}
.sum3{display:flex;gap:var(--s6);justify-content:center;align-items:baseline;font-weight:800;font-size:40px;line-height:1}
.sum3 .n{display:inline-flex;flex-direction:column;align-items:center;gap:4px}.sum3 small{font-size:16px;opacity:.7}
.sum3 .bad{color:var(--rose)}.sum3 .late{color:#2f6fe0}
#lessons,#events{width:100%}
#stp{gap:var(--s5)}
.nm small{font-weight:600;color:#5b5ea8;font-size:12.5px}

/* the lesson picker (admin): designed, not the browser's */
.picker{position:relative}
#pickbtn{min-height:44px;min-width:240px;padding:0 var(--s4);border-radius:var(--r-pill);border:2px solid var(--indigo);background:var(--white);color:var(--indigo);font-weight:800;font-size:16px;display:flex;align-items:center;justify-content:space-between;gap:var(--s3)}
#pickbtn .pl{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:300px}
#pickbtn .ms{transition:transform .18s}#pickbtn.open{background:var(--indigo);color:var(--white)}#pickbtn.open .ms{transform:rotate(180deg)}
#picklist{position:absolute;top:calc(100% + 8px);inset-inline-start:0;z-index:9;min-width:340px;max-height:min(70vh,520px);overflow-y:auto;background:var(--paper);border-radius:var(--r-m);box-shadow:0 12px 36px rgba(48,53,208,.35);padding:var(--s2);display:flex;flex-direction:column;gap:2px}
#picklist .pg{padding:var(--s3) var(--s3) 4px;font-size:12.5px;font-weight:800;color:#8a8cc4;letter-spacing:.04em}
#picklist .pi{display:flex;align-items:center;gap:var(--s3);border:0;background:transparent;color:var(--ink);text-align:start;padding:10px var(--s3);border-radius:var(--r-s);font-weight:700;font-size:15px}
#picklist .pi:hover,#picklist .pi:focus-visible{background:var(--pale-violet);outline:none}
#picklist .pi.on{background:rgba(48,53,208,.09);color:var(--indigo)}
#picklist .pn{flex:1;display:flex;align-items:center;gap:var(--s2)}
#picklist .pt{color:#5b5ea8;font-weight:700;font-size:13.5px}
#picklist .ck{color:var(--teal);font-size:20px}

/* the way back: always at the top, big */
a.back.top{position:sticky;top:calc(12px + env(safe-area-inset-top,0px));align-self:flex-start;z-index:6;width:60px;height:60px;min-height:0;border-radius:50%;background:var(--indigo);color:var(--white);display:flex;align-items:center;justify-content:center;box-shadow:0 4px 16px rgba(48,53,208,.4);margin:0}
a.back.top .ms{font-size:34px}
a.back.top:hover{filter:brightness(1.1)}

/* the admin pages: made for the desktop. A sheet, like Google Sheets: tight rows, grid lines, cells you type in */
.page.desk{max-width:none;align-items:stretch;gap:12px;padding:0 16px 24px}
.phead{position:sticky;top:0;z-index:6;display:flex;align-items:center;gap:16px;padding:10px 0;background:var(--field)}
.phead h1{font-size:22px;margin:0}
.phead .grow{flex:1}
.phead a.back.top{position:static}
.phead .tools{display:flex;align-items:center;gap:8px}
.sheet{width:100%;border-collapse:collapse;background:#fff;font-size:14px;color:#1d1f4d}
.sheet th,.sheet td{border:1px solid #d6d6e2;padding:0 8px;height:30px;white-space:nowrap;text-align:start;font-weight:500}
.sheet thead th{background:#f1eff5;color:#4b4fa6;font-weight:800;position:sticky;top:80px;z-index:3;font-size:13px}
.sheet .rn{width:36px;min-width:36px;background:#f1eff5;color:#8a8cc4;text-align:center;font-weight:700;font-size:12px;padding:0}
.sheet tbody tr:hover td{background:#faf9ff}
.sheet input,.sheet select{width:100%;height:28px;border:0;background:transparent;font:inherit;color:inherit;padding:0 2px;outline:none}
.sheet select{cursor:pointer}
.sheet td:focus-within{outline:2px solid var(--blue);outline-offset:-2px;background:#fff}
.sheet .nmc{min-width:240px}
.sheet [contenteditable]{min-height:28px;line-height:28px;outline:none;white-space:nowrap;overflow:hidden}
.sheet [contenteditable] b{font-weight:900;color:var(--indigo)}
.sheet .th22{width:24px;height:24px;border-radius:50%;object-fit:cover;vertical-align:middle;display:inline-block;background:var(--pale-violet)}
.sheet .ic{border:0;background:transparent;color:var(--rose);width:26px;height:26px;padding:0;border-radius:var(--r-s);display:inline-flex;align-items:center;justify-content:center}
.sheet .ic:hover{background:var(--pale-violet)}.sheet .ic .ms{font-size:20px}
.sheet a.ic{color:var(--indigo);text-decoration:none}
.sheet .num{text-align:center;font-weight:800}.sheet .num.bad{color:var(--rose)}.sheet .num.late{color:#2f6fe0}
.sheet .saved{color:var(--teal);display:inline-block;min-width:20px;vertical-align:middle}
.sheet .les{font-weight:500;color:#4b4fa6;white-space:normal;max-width:420px}
.sheet .code{font-weight:800;font-size:15px;letter-spacing:.05em;color:var(--indigo)}
.addrow2{display:flex;gap:8px;align-items:center}
.addrow2 input{height:36px;border:1px solid #c9c9d8;border-radius:var(--r-s);padding:0 10px;font:inherit;background:#fff;color:var(--indigo);min-width:240px}
.addrow2 select{height:36px;border:1px solid #c9c9d8;border-radius:var(--r-s);padding:0 8px;font:inherit;background:#fff;color:var(--indigo)}
.addrow2 .round{width:36px;height:36px}.addrow2 .round .ms{font-size:20px}
.pairs{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);gap:16px;align-items:start}
.sbar{display:flex;align-items:center;gap:16px}
.sbar img,.sbar .ph0{width:44px;height:44px;border-radius:50%;object-fit:cover;background:var(--pale-violet);display:flex;align-items:center;justify-content:center;color:var(--indigo)}
.sbar h1 b{font-weight:900}
.sbar .tot{display:flex;gap:18px;align-items:baseline;font-weight:800;font-size:22px}
.sbar .tot small{font-size:13px;opacity:.7;margin-inline-start:3px}

th.who span b{font-weight:900}

/* the years: א ב ג ד as circles (a year with nothing in it yet is grey) */
#courses{gap:var(--s3)}
.years{display:flex;gap:var(--s2);align-items:center}
.yc{width:42px;height:42px;border-radius:50%;border:2px solid var(--indigo);background:var(--white);color:var(--indigo);font-weight:800;font-size:17px;padding:0;display:flex;align-items:center;justify-content:center}
.yc.on{background:var(--indigo);color:var(--white)}
.yc:disabled{border-color:var(--light-grey);background:var(--pale-violet);color:var(--light-grey);cursor:default}

/* the צ of Tzahal (reserve duty) and the red thermometer (sick) */
.zhal{display:inline-flex;align-items:center;justify-content:center;width:22px;height:22px;border-radius:6px;background:var(--indigo);color:var(--white);font-size:14px;font-weight:900;font-style:normal;line-height:1}
.ms.sickic{color:var(--rose)}
body.desk #gal em.flag{background:var(--white);box-shadow:0 1px 6px rgba(48,53,208,.35);color:var(--rose)}
body.desk #gal em.flag .zhal{width:20px;height:20px;font-size:13px}
body.desk #gal em.flag .ms{font-size:18px}
.flagi{display:inline-flex;vertical-align:middle;margin-inline-start:6px}
.flagi .zhal{width:18px;height:18px;font-size:12px}.flagi .ms{font-size:20px}
td.cell.exc{text-align:center}td.cell.exc .zhal{width:18px;height:18px;font-size:12px}td.cell.exc .ms{font-size:20px}
#ctx button[data-flag] .zhal{width:20px;height:20px;font-size:13px}
.mut{color:#8a8cc4;font-weight:600}

/* a student's card in the table's place */
.scard{padding:14px 16px 20px;display:flex;flex-direction:column;gap:16px}
.chead{display:flex;align-items:center;gap:16px}
.chead img,.chead .ph0{width:52px;height:52px;border-radius:50%;object-fit:cover;background:var(--pale-violet);display:flex;align-items:center;justify-content:center;color:var(--indigo)}
.chead h2{margin:0;font-size:24px;font-weight:800;color:var(--indigo)}.chead h2 b{font-weight:900}
.chead .snote{color:#4b4fa6;font-weight:700}
.chead .grow{flex:1}
.chead .tot{display:flex;gap:20px;align-items:baseline;font-weight:800;font-size:24px}.chead .tot small{font-size:13px;opacity:.7;margin-inline-start:3px}
.chead .tot .bad{color:var(--rose)}.chead .tot .late{color:#2f6fe0}
.ctools{display:flex;gap:12px}
.tool{width:60px;height:60px;border-radius:14px;border:2px solid var(--light-grey);background:var(--white);display:flex;align-items:center;justify-content:center;padding:0}
.tool.on{border-color:var(--indigo);box-shadow:0 0 0 4px rgba(48,53,208,.18)}
.tool .zhal{width:36px;height:36px;font-size:24px;border-radius:10px}.tool .ms{font-size:38px}
.cal{display:flex;gap:22px;overflow-x:auto;padding-bottom:8px;-webkit-user-select:none;user-select:none}
.cm{flex:none}
.cmh{font-weight:800;color:var(--indigo);margin-bottom:6px;font-size:16px}
.cw,.cg{display:grid;grid-template-columns:repeat(7,44px);gap:4px}
.cw{font-size:12px;color:#8a8cc4;text-align:center;font-weight:700;margin-bottom:4px}
.cd{height:44px;border-radius:10px;border:1px solid #d6d6e2;background:#fff;color:#1d1f4d;font-weight:700;padding:0;position:relative;cursor:pointer;font-size:14px}
.cd .ci{position:absolute;bottom:1px;inset-inline-end:3px;line-height:1}
.cd .ci .zhal{width:15px;height:15px;font-size:10px;border-radius:4px}.cd .ci .ms{font-size:16px}
.cd.we{background:#f1eff5}.cd.td{outline:2px solid var(--indigo);outline-offset:-2px}
.cd.reserve{background:#dfe0ff;border-color:var(--indigo)}.cd.sick{background:#ffe0e6;border-color:var(--rose)}
.cd:hover{filter:brightness(.97)}
.scard .pairs{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);gap:16px;align-items:start}

.addrow2 input,.tools input[type=email],.tools input[type=tel]{height:36px;border:1px solid #c9c9d8;border-radius:var(--r-s);padding:0 10px;font:inherit;background:#fff;color:var(--indigo)}
.tools #newemail{min-width:200px}.tools #newphone{min-width:130px}
.sheet input[type=email],.sheet input[type=tel]{text-align:start}

/* the page of the class: a title that opens a menu, a hamburger, the student sheet; lateness is yellow */
:root{--yellow:#FFC21A}
#tab{gap:var(--s3)}
#titl{flex:1;min-width:0;min-height:52px;border:2px solid var(--indigo);border-radius:var(--r-pill);background:var(--white);color:var(--indigo);padding:0 var(--s4);display:flex;align-items:center;justify-content:space-between;gap:var(--s3)}
#titl .tn{font-weight:800;font-size:16px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex:0 1 auto}
#titl .ts{display:flex;gap:10px;align-items:baseline;font-size:18px;font-weight:800;flex:none;margin-inline-start:auto}
#titl[aria-expanded=true]{background:var(--indigo);color:var(--white)}
#sum{flex:none;font-size:18px}
#tmenu,#bmenu{position:absolute;z-index:9;background:var(--paper);border-radius:var(--r-m);box-shadow:0 12px 36px rgba(48,53,208,.35);padding:var(--s2);display:flex;flex-direction:column;gap:2px;max-height:70dvh;overflow-y:auto}
#tmenu{top:calc(72px + env(safe-area-inset-top,0px));left:var(--s3);right:var(--s3)}
#bmenu{top:calc(72px + env(safe-area-inset-top,0px));inset-inline-end:var(--s3);min-width:220px}
#tmenu .tg{padding:var(--s3) var(--s3) 4px;font-size:12.5px;font-weight:800;color:#8a8cc4;letter-spacing:.04em}
#tmenu .ti{display:flex;align-items:center;gap:var(--s3);border:0;background:transparent;color:var(--ink);text-align:start;padding:11px var(--s3);border-radius:var(--r-s);font-weight:700;font-size:15px}
#tmenu .ti.on{background:rgba(48,53,208,.09);color:var(--indigo)}
#tmenu .tt{flex:1}#tmenu .tm{color:#5b5ea8;font-size:13.5px;font-weight:700}#tmenu .ck{color:var(--teal);font-size:20px}
#bmenu button{display:flex;align-items:center;gap:var(--s3);border:0;background:transparent;color:var(--ink);font-weight:700;font-size:16px;padding:12px var(--s3);border-radius:var(--r-s);text-align:start}
#bmenu button.neg{color:var(--rose)}#bmenu button:hover,#tmenu .ti:hover{background:var(--pale-violet)}
#gal .late img{border-color:var(--yellow)}
#gal small{background:var(--yellow);color:var(--indigo)}
#ss{position:absolute;inset:0;z-index:8;background:rgba(48,53,208,.5);display:flex;align-items:flex-end}
#ssbox{width:100%;max-height:82%;overflow-y:auto;background:var(--paper);border-radius:var(--r-l) var(--r-l) 0 0;padding:var(--s4) var(--s4) calc(var(--s5) + env(safe-area-inset-bottom,0px));display:flex;flex-direction:column;gap:var(--s3)}
.ssh{display:flex;align-items:center;gap:var(--s3)}
.ssh img,.ssh .ph0{width:52px;height:52px;border-radius:50%;object-fit:cover;background:var(--pale-violet);display:flex;align-items:center;justify-content:center;color:var(--indigo)}
.ssh h2{flex:1;margin:0;font-size:22px;font-weight:600;color:var(--indigo)}.ssh h2 b{font-weight:900}
#ssnote{width:100%;border:2px solid var(--light-grey);border-radius:var(--r-m);padding:var(--s3);font:inherit;color:var(--indigo);background:var(--white);resize:none}
#ssnote:focus{border-color:var(--blue);outline:none}
#sscal{display:flex;gap:var(--s5);overflow-x:auto;padding-bottom:var(--s2);-webkit-overflow-scrolling:touch}
.sm{flex:none}.smh{font-weight:800;color:var(--indigo);margin-bottom:6px}
.sw,.sg{display:grid;grid-template-columns:repeat(7,40px);gap:4px}
.sw{font-size:12px;color:#8a8cc4;text-align:center;font-weight:700;margin-bottom:4px}
.sd{height:40px;border-radius:10px;border:1px solid #e1e0ea;background:#fff;color:#8a8cc4;font-weight:700;font-size:14px;display:flex;align-items:center;justify-content:center}
.sd.ld{background:var(--pale-violet);border-color:#dedbe6}
.sd.present{background:rgba(21,194,159,.18);border-color:transparent;color:#0e8a70}
.sd.late{background:var(--yellow);border-color:transparent;color:var(--indigo)}
.sd.absent{background:var(--rose);border-color:transparent;color:var(--white)}
.sd.td{outline:2px solid var(--indigo);outline-offset:-2px}

/* the card's back arrow and the student's circle: the same size */
.chead .round.big,.chead img,.chead .ph0{width:64px;height:64px;flex:none}

/* the access table by years */
.sheet tr.ysec td{background:#f1eff5;color:var(--indigo);font-weight:800;font-size:15px;height:36px}
.sheet td.empty{color:#b9b9cf;text-align:center;height:26px}
.sheet td.dh2{color:#4b4fa6;font-weight:600}

/* outside the lesson's day and hours the balls rest */
#idle{position:fixed;z-index:1;left:0;right:0;top:34%;display:flex;flex-direction:column;align-items:center;gap:var(--s2);text-align:center;color:var(--indigo);padding:0 var(--s5);pointer-events:none}
#idle .ms{font-size:56px;color:var(--light-grey)}
#idle b{font-size:22px}
#idle small{font-size:15px;color:#5b5ea8;font-weight:700}

/* a long press on a picture is ours (the student sheet), not iOS's "Share / Save to Photos / Copy" menu */
body.balls img,body.balls button{-webkit-touch-callout:none;-webkit-user-select:none;user-select:none}
#gal img,#ssimg,#camimg{pointer-events:none;-webkit-user-drag:none}
#gal button{-webkit-touch-callout:none;touch-action:manipulation}

/* the students' page: the first name above each picture; the hamburger's menu opens under the hamburger */
#gal button{aspect-ratio:auto;display:flex;flex-direction:column;align-items:stretch;gap:3px}
#gal img{width:100%;height:auto;aspect-ratio:1}
#gal .gn{font-size:13px;font-weight:800;color:var(--indigo);text-align:center;line-height:1.1;min-height:15px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#gal small{bottom:0}
#bmenu{inset-inline-end:auto;inset-inline-start:var(--s3)}

/* the first steps: a message floating over the students' faces, in the middle of the screen */
#onb{position:fixed;inset:0;z-index:30;display:flex;align-items:center;justify-content:center;padding:var(--s5);background:rgba(36,40,150,.14);transition:opacity .25s}
#onb.out{opacity:0}
.obcard{width:100%;max-width:340px;text-align:center;background:linear-gradient(180deg,var(--indigo) 0%,var(--blue) 100%);color:var(--white);border-radius:28px;padding:32px 24px 18px;box-shadow:0 24px 60px rgba(24,28,120,.5),0 2px 0 rgba(255,255,255,.25) inset;animation:obin .35s cubic-bezier(.2,.9,.3,1.2)}
@keyframes obin{from{opacity:0;transform:translateY(18px) scale(.94)}to{opacity:1;transform:none}}
.obcard h1{margin:0;font-size:32px;font-weight:800;line-height:1.1}
.obcard p{margin:var(--s4) 0 0;font-size:18px;line-height:1.55;font-weight:600;color:rgba(250,245,251,.95)}
.obcard p small{display:block;margin-top:6px;font-size:15px;font-weight:700;opacity:.85}
.obh{font-weight:800;white-space:nowrap}
.obbar{display:flex;align-items:center;justify-content:space-between;margin-top:var(--s5)}
.obbar button{border:0;background:transparent;color:var(--white);font-weight:800;font-size:17px;padding:var(--s3) var(--s3);min-width:64px;border-radius:var(--r-pill)}
.obbar .obnext{background:var(--white);color:var(--indigo);padding:var(--s3) var(--s5)}
.obbar .obskip{opacity:.8}
.obdots{display:flex;gap:8px}.obdots i{width:8px;height:8px;border-radius:50%;background:rgba(250,245,251,.45)}.obdots i.on{background:var(--white);width:22px;border-radius:5px}

.obsw{display:flex;align-items:center;justify-content:center;gap:var(--s3);margin-top:var(--s5);font-weight:800;font-size:17px}
.obsw .ms{font-size:22px;vertical-align:middle}
.obball{width:72px;height:72px;border-radius:50%;background:var(--pale-violet);color:var(--indigo);display:flex;align-items:center;justify-content:center;font-size:40px!important;flex:none}
.obhere,.obmiss{display:flex;align-items:center;gap:4px;white-space:nowrap}
.obhere{color:var(--teal)}.obmiss{color:var(--rose)}
.obball{width:88px;height:88px;overflow:hidden;box-shadow:0 0 0 3px var(--white),0 6px 16px rgba(24,28,120,.45)}.obball img{width:100%;height:100%;object-fit:cover;object-position:50% 0;display:block;pointer-events:none}

.obsw{gap:6px}
.obarr{display:flex;align-items:center;width:86px;height:60px;color:var(--white);font-size:17px;font-weight:800;filter:drop-shadow(0 4px 6px rgba(24,28,120,.35))}
.obarr b{display:flex;align-items:center;height:100%;width:100%;font-weight:800}
.obhere,.obmiss{gap:0}
.obhere b{background:var(--teal);justify-content:flex-start;padding-left:10px;clip-path:polygon(0 24%,66% 24%,66% 0,100% 50%,66% 100%,66% 76%,0 76%)}
.obmiss b{background:var(--rose);justify-content:flex-end;padding-right:10px;clip-path:polygon(100% 24%,34% 24%,34% 0,0 50%,34% 100%,34% 76%,100% 76%)}

.obsw{gap:2px}.obsw .obarr{width:94px;height:56px;filter:drop-shadow(0 4px 5px rgba(24,28,120,.4))}.obarr svg{width:100%;height:100%;overflow:visible}
.obhere b,.obmiss b{all:unset}
.obball img{object-position:50% 50%}

.obsw{gap:8px}
.obsw .obpill{display:flex;align-items:center;gap:4px;height:44px;padding:0 12px;border-radius:var(--r-pill);background:var(--white);font-size:17px;font-weight:800;white-space:nowrap;box-shadow:0 4px 12px rgba(24,28,120,.3)}
.obsw .obpill .ms{font-size:26px;font-variation-settings:'wght' 600}
.obsw .obhere{color:var(--teal)}.obsw .obmiss{color:var(--rose)}

@keyframes obgoR{0%,100%{transform:translateX(0)}50%{transform:translateX(7px)}}
@keyframes obgoL{0%,100%{transform:translateX(0)}50%{transform:translateX(-7px)}}
.obsw .obhere .ms{animation:obgoR 1.1s ease-in-out infinite}
.obsw .obmiss .ms{animation:obgoL 1.1s ease-in-out .55s infinite}
@media (prefers-reduced-motion:reduce){.obsw .obpill .ms{animation:none}}

.obsw.one{flex-wrap:wrap;gap:12px}
.obball.wrap{position:relative;overflow:visible;box-shadow:none}
.obball.wrap img{width:100%;height:100%;border-radius:50%;object-fit:cover;box-shadow:0 0 0 3px var(--white),0 6px 16px rgba(24,28,120,.45)}
.obball.late img{box-shadow:0 0 0 4px var(--blue-2),0 6px 16px rgba(24,28,120,.45)}
.obbadge{position:absolute;bottom:-4px;inset-inline-end:-6px;min-width:30px;height:30px;border-radius:50%;background:var(--white);color:var(--indigo);display:flex;align-items:center;justify-content:center;box-shadow:0 2px 8px rgba(24,28,120,.4)}
.obbadge .ms{font-size:20px}.obbadge.late{background:var(--blue-2)}
.obbadge .zhal,.obpill .zhal{width:20px;height:20px;font-size:13px;border-radius:5px}
.obpill.tx{color:var(--rose);font-size:15px}.obpill.tx.ind{color:var(--indigo)}
.obpill.tx .ms{font-size:22px}
.obfab{width:84px;height:84px;border-radius:50%;background:var(--white);color:var(--indigo);display:flex;align-items:center;justify-content:center;box-shadow:0 8px 20px rgba(24,28,120,.45);animation:obpulse 1.6s ease-in-out infinite}
.obfab .ms{font-size:46px}
.obfab.pc{background:var(--indigo);color:var(--white);box-shadow:0 0 0 3px var(--white),0 8px 20px rgba(24,28,120,.45)}
@keyframes obpulse{0%,100%{transform:scale(1)}50%{transform:scale(1.08)}}
@keyframes obpress{0%,100%{transform:scale(1)}50%{transform:scale(.9)}}
.obball.press{animation:obpress 1.4s ease-in-out infinite}
.obnote{display:flex;align-items:center;gap:6px;height:44px;padding:0 14px;border-radius:var(--r-pill);background:var(--white);color:var(--indigo);font-weight:800;font-size:16px}
.obnote .ms{font-size:22px}
.obtitle{display:flex;align-items:center;gap:6px;height:48px;padding:0 18px;border-radius:var(--r-pill);background:var(--white);color:var(--indigo);font-weight:800;font-size:18px;box-shadow:0 4px 12px rgba(24,28,120,.3)}
.obtitle .ms{font-size:26px;animation:obdown 1.2s ease-in-out infinite}
@keyframes obdown{0%,100%{transform:translateY(-2px)}50%{transform:translateY(4px)}}
@media (prefers-reduced-motion:reduce){.obfab,.obball.press,.obtitle .ms{animation:none}}
.obcard p{font-size:17px}
.obsw.one.col{flex-direction:column}.obrow{display:flex;gap:8px;justify-content:center}.obcard{min-height:330px;display:flex;flex-direction:column;justify-content:space-between}.obcard .obsw{margin-block:auto}

.obgal{display:grid;grid-template-columns:repeat(4,1fr);gap:12px 8px;margin-block:var(--s4) auto;width:100%}
.obs{position:relative;display:flex;flex-direction:column;align-items:center;gap:4px}
.obs img{width:56px;height:56px;border-radius:50%;object-fit:cover;box-shadow:0 0 0 3px var(--teal)}
.obs.bad img{box-shadow:0 0 0 3px var(--rose)}.obs.late img{box-shadow:0 0 0 3px var(--blue-2)}
.obs em{font-style:normal;font-size:12px;font-weight:700;color:rgba(250,245,251,.95);white-space:nowrap}
.obs small{position:absolute;top:36px;inset-inline-end:2px;width:22px;height:22px;border-radius:50%;background:var(--blue-2);color:var(--indigo);display:flex;align-items:center;justify-content:center}
.obs small .ms{font-size:16px}
#bmenu{position:fixed;z-index:40}
.obcard p{margin-bottom:var(--s4)}.obcard .obsw,.obcard .obgal{margin-block:var(--s4);margin-top:auto;margin-bottom:auto;padding-top:var(--s3)}
body.demo #body{background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='400' height='200' viewBox='0 0 400 200'%3E%3Ctext x='200' y='130' text-anchor='middle' font-family='Assistant%2Csans-serif' font-weight='800' font-size='125' fill='%23FC2B55' fill-opacity='.55' transform='rotate%28-14 200 100%29'%3E%D7%93%D7%95%D7%92%D7%9E%D7%90%3C/text%3E%3C/svg%3E") center 0/min(94%,420px) auto repeat-y local}
.sd.ed{cursor:pointer;-webkit-tap-highlight-color:transparent;user-select:none}.sd.ed:active{transform:scale(.92)}

#ssact{display:flex;gap:var(--s3);margin:var(--s3) 0}
.ssb{flex:1;display:flex;align-items:center;justify-content:center;gap:var(--s2);height:48px;border-radius:var(--r-pill);background:var(--indigo);color:var(--white);font-weight:800;font-size:16px;text-decoration:none}
.ssb .ms{font-size:22px}.ssb:active{filter:brightness(.92)}
.ssb svg{width:24px;height:24px}.ssb.round{flex:none;width:48px;padding:0}

#ssact{display:flex;gap:var(--s2);margin:0 var(--s2);flex:none}#ssact[hidden]{display:none}
#ssact .ssb.round{width:36px;height:36px;flex:none}#ssact .ssb svg{width:20px;height:20px}#ssact .ssb .ms{font-size:20px}
.ssh h2{flex:0 1 auto}#ssact{margin-inline-end:auto}

.obcard{min-height:0;justify-content:flex-start}
.obcard .obsw,.obcard .obgal{margin-top:var(--s3);margin-bottom:var(--s3)}
.obcard .obbar{margin-top:auto;padding-top:var(--s4)}
.obcard h1{margin-bottom:var(--s2)}

.obcard .obbar{display:grid;grid-template-columns:1fr auto 1fr;align-items:center;column-gap:var(--s3)}
.obcard .obbar .obskip{justify-self:start;min-width:0;padding:var(--s3) 0}
.obcard .obbar .obnext{justify-self:end;min-width:92px;text-align:center}

.obcard .obbar{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;row-gap:var(--s3)}
.obcard .obbar .obdots{order:-1;flex:0 0 100%;justify-content:center}
.obcard .obbar .obskip{padding:var(--s3) 0;min-width:0}

/* the finish: the hat turns over in the middle of the screen and the numbers pour out of it */
#done{position:fixed;inset:0;padding:72px 0 calc(66dvh + 30px);box-sizing:border-box;z-index:4;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;gap:0;cursor:pointer;-webkit-tap-highlight-color:transparent}
.dcap{width:100px;height:100px;border-radius:50%;background:var(--indigo);color:var(--white);display:flex;align-items:center;justify-content:center;box-shadow:0 12px 32px rgba(48,53,208,.5);position:relative;z-index:2}
.dcap .ms{font-size:56px}
.dnum{display:flex;align-items:baseline;gap:12px;margin-top:6px;font-size:68px;font-weight:800;line-height:1;position:relative;z-index:1}
.dnum .ds{font-style:normal;color:var(--light-grey);font-weight:600;font-size:52px}
.dnum .dg{font-size:68px;font-weight:800;line-height:1}.dnum .dg.ok{color:var(--teal)}.dnum .dg.bad{color:var(--rose)}

#lo{position:fixed;inset:0;z-index:50;background:rgba(36,40,150,.55);display:flex;align-items:center;justify-content:center;padding:var(--s5)}
#lo[hidden]{display:none}
#lobox{width:100%;max-width:340px;background:var(--paper);color:var(--ink);border-radius:24px;padding:28px 22px 18px;text-align:center;box-shadow:0 24px 60px rgba(24,28,120,.5)}
#lobox>.ms{font-size:40px;color:var(--rose)}
#lobox h2{margin:var(--s2) 0 var(--s3);font-size:21px;font-weight:800;color:var(--indigo);line-height:1.25}
#lobox p{margin:0;font-size:16px;line-height:1.5;font-weight:600}#lobox p small{display:block;margin-top:var(--s2);font-size:14px;color:#5b5ea8;font-weight:600}
#lobox .lob{display:flex;gap:var(--s3);margin-top:var(--s5)}
#lobox .lob button{flex:1;height:48px;border:0;border-radius:var(--r-pill);font-weight:800;font-size:16px}
#lono{background:var(--pale-violet);color:var(--indigo)}#loyes{background:var(--rose);color:var(--white)}

/* the front door: a riddle. Nothing here says what the site is */
body.riddle{margin:0;min-height:100dvh;display:flex;align-items:center;justify-content:center;background:var(--paper);color:var(--ink)}
body.riddle main{width:100%;max-width:420px;padding:32px 24px;text-align:center;display:flex;flex-direction:column;align-items:center;gap:var(--s3)}
body.riddle .ms{font-size:104px;color:var(--rose)}
body.riddle h1{margin:var(--s3) 0 0;font-size:24px;font-weight:800;color:var(--indigo);line-height:1.25}
body.riddle p{margin:0;font-size:19px;font-weight:600}
body.riddle form{display:flex;gap:var(--s2);width:100%;margin-top:var(--s3)}
body.riddle input{flex:1;min-width:0;height:48px;border-radius:var(--r-pill);border:2px solid var(--light-grey);background:var(--white);padding:0 18px;font:inherit;font-size:17px;color:var(--ink);outline:none}
body.riddle input:focus{border-color:var(--indigo)}
body.riddle button{height:48px;padding:0 24px;border:0;border-radius:var(--r-pill);background:var(--indigo);color:var(--white);font:inherit;font-size:17px;font-weight:800}
body.riddle button:disabled{opacity:.6}
body.riddle output{min-height:24px;font-size:17px;font-weight:600;color:#5b5ea8}
body.riddle{direction:ltr}
.asks{margin-top:var(--s6)}.asks h2{font-size:20px;color:var(--indigo);margin:0 0 var(--s3)}.asks td.q{white-space:pre-wrap;word-break:break-word;max-width:520px}.asks td.t{white-space:nowrap;color:#5b5ea8}
body.riddle .clk{display:block;font-variant-numeric:tabular-nums;font-size:22px;font-weight:700;color:var(--indigo);line-height:1.5}body.riddle .clk b{font-size:30px;font-weight:800;color:var(--rose)}
body.riddle .lw{display:block;margin-bottom:var(--s3);font-size:19px;font-weight:800;color:var(--rose);line-height:1.4}
body.riddle .lw{margin:var(--s3) 0 0;font-size:13px;font-weight:600;color:#5b5ea8;line-height:1.4}
#gal.view button img{border-color:#cfcde0}#gal small.abn{position:absolute;bottom:0;inset-inline-end:0;min-width:22px;height:22px;padding:0 5px;border-radius:11px;background:var(--rose);color:var(--white);font-size:13px;font-weight:800;display:flex;align-items:center;justify-content:center;box-sizing:border-box}

/* codes for lecturers */
#inv{position:fixed;inset:0;z-index:45;background:rgba(36,40,150,.55);display:flex;align-items:flex-end;justify-content:center}
#inv[hidden]{display:none}
#invbox{width:100%;max-width:560px;max-height:86dvh;overflow-y:auto;background:var(--paper);color:var(--ink);border-radius:24px 24px 0 0;padding:20px 16px calc(20px + env(safe-area-inset-bottom,0px))}
.invh{display:flex;align-items:center;justify-content:space-between;margin-bottom:var(--s3)}.invh h2{margin:0;font-size:22px;font-weight:800;color:var(--indigo)}
.invr{display:flex;align-items:center;gap:var(--s3);padding:10px 0;border-top:1px solid #ece9f2}.invr:first-child{border-top:0}
.invn{flex:1;min-width:0;display:flex;flex-direction:column}.invn b{font-size:17px;font-weight:800;color:var(--indigo)}.invn small{font-size:13px;color:#5b5ea8;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.invc{font-size:20px;font-weight:800;letter-spacing:1px;color:var(--rose);font-variant-numeric:tabular-nums}.invu{font-size:13px;font-weight:700;color:#5b5ea8}
#invmsg{min-height:20px;margin:var(--s3) 0 0;font-size:14px;font-weight:700;color:var(--indigo);text-align:center}
#pchelp{margin:var(--s4) 0 0;font-size:16px;font-weight:700;line-height:1.5;color:var(--indigo);text-align:center}#pchelp b{font-weight:800;color:var(--rose);unicode-bidi:isolate}
#pctitle{margin:0 0 var(--s3);padding-inline:36px;font-size:18px;font-weight:800;line-height:1.3;color:var(--indigo);text-align:center}#pctitle small{display:block;margin-top:2px;font-size:14px;font-weight:600;color:#5b5ea8}
#qgo{display:block;margin:14px auto 0;padding:12px 30px;border:0;border-radius:999px;background:#3333CC;color:#fff;font:800 17px Assistant,sans-serif;cursor:pointer}
#qgo:disabled{opacity:.5}

/* the step between the code and the passkey */
body.riddle .wel{width:100%;display:flex;flex-direction:column;align-items:center;gap:var(--s3);text-align:center}
body.riddle .wel h1{margin:0;font-size:22px}
body.riddle .wname{font-size:34px;font-weight:800;color:var(--rose);line-height:1.2}
body.riddle .wel ul{list-style:none;margin:var(--s2) 0;padding:0;width:100%;display:flex;flex-direction:column;gap:8px}
body.riddle .wel li{display:flex;flex-direction:column;gap:2px;background:var(--white);border-radius:16px;padding:10px 14px}
body.riddle .wel li b{font-size:18px;font-weight:800;color:var(--indigo)}body.riddle .wel li span{font-size:14px;font-weight:600;color:#5b5ea8}
body.riddle .wel .yes{width:100%}
body.riddle .wn{display:flex;align-items:center;gap:10px;margin-top:var(--s3);font-size:14px;font-weight:600;color:#5b5ea8}
body.riddle .wn .no{width:36px;height:36px;padding:0;display:flex;align-items:center;justify-content:center;background:var(--rose)}
body.riddle .wn .no .ms{font-size:22px;color:#fff}
body.riddle .wh{font-size:14px;font-weight:600;color:#5b5ea8}
body.riddle .wel output:empty{display:none}
body.riddle .wel li{transition:opacity .4s}body.riddle .wel li.fade{opacity:0}
td.kc{width:44px;padding:0;text-align:center}

#gal small .zhal{width:16px;height:16px;font-size:11px;border-radius:5px}#gal small .ms{font-size:18px}
