:root{font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;color:#142b42;background:#edf3f8;color-scheme:light;--ink:#142b42;--muted:#657c90;--line:#dce5ee;--navy:#0b2e4f;--blue:#0759ad;--blue2:#0f69c2;--green:#077c57}
*{box-sizing:border-box}body{margin:0}button,input,select,textarea{font:inherit}button{cursor:pointer}button:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible{outline:3px solid #77bfff;outline-offset:2px}button:disabled{opacity:.55;cursor:wait}
.app{min-height:100dvh;display:flex;flex-direction:column}.topbar{display:flex;justify-content:space-between;align-items:center;gap:12px;background:var(--navy);color:white;padding:17px max(19px,env(safe-area-inset-right)) 17px max(19px,env(safe-area-inset-left));box-shadow:0 3px 16px #0a264535}.top-left{display:flex;align-items:center;gap:11px}.mark{width:40px;height:40px;border-radius:12px;background:#ffffff22;display:grid;place-items:center;font-size:24px;font-weight:900}.brand{font-size:22px;font-weight:850;letter-spacing:-.055em}.brand span{font-size:18px;font-weight:600;color:#c6dced}.subtitle{font-size:11px;color:#c5d9e9;letter-spacing:.04em;margin-top:2px}.top-right{text-align:right;display:flex;flex-direction:column;align-items:flex-end;gap:6px}.connection{font-size:11px;color:#b2dae4}.connection:before{content:'●';font-size:8px;margin-right:6px}.connection.online:before{color:#54dfb0}.connection.offline:before{color:#ffb6a3}.logout{background:transparent;border:0;color:#eff9ff;font-size:12px;text-decoration:underline;padding:2px 0}
main{flex:1;width:min(100%,780px);margin:0 auto;padding:22px 17px 33px}.hidden{display:none!important}.login-area{max-width:460px;margin:6vh auto 0}.login-card,.card,.item-card{background:white;border:1px solid var(--line);border-radius:19px;box-shadow:0 6px 26px #17466f0b}.login-card{padding:29px 24px}.eyebrow{font-size:11px;letter-spacing:.13em;font-weight:850;color:#54718c;margin-bottom:8px}.login-card h1,.welcome h1{margin:0;font-weight:850;font-size:29px;letter-spacing:-.045em;line-height:1.16}.intro{color:var(--muted);font-size:14px;line-height:1.55;margin:13px 0 22px}form label,.login-card label{display:block;font-size:13px;font-weight:700;margin:17px 0 7px}label input,label select,label textarea,.login-card input,select,textarea{width:100%;margin:7px 0 0;border:1px solid #c8d7e4;border-radius:12px;padding:12px 13px;color:var(--ink);background:#fff;min-height:48px;font-size:16px}textarea{resize:vertical}select{cursor:pointer}.btn{display:block;border:0;border-radius:12px;padding:14px 17px;min-height:49px;width:100%;font-size:15px;font-weight:800}.primary{background:var(--blue);color:white}.btn:hover:not(:disabled){filter:brightness(.96)}.login-card .btn{margin-top:23px}.form-note{font-size:13px;color:#54708a;line-height:1.5;min-height:21px;margin-top:15px}.form-note.error{color:#b12c38}.form-note.success{color:var(--green)}.privacy-line{text-align:center;font-size:12px;color:#788c9e;padding:12px}.welcome{display:flex;align-items:center;justify-content:space-between;gap:15px;margin:8px 2px 20px}.welcome .intro{margin:8px 0 0}.tab{display:grid;gap:13px}.card{padding:19px}.section-label{font-size:11px;letter-spacing:.1em;font-weight:850;color:#66829b}.status-card{background:linear-gradient(126deg,#fff 52%,#e9f8f1);border-color:#d4e8de}.current-status{display:flex;align-items:center;gap:11px;font-size:23px;margin:13px 0 4px}.status-dot{width:13px;height:13px;background:#11a474;border-radius:50%;flex-shrink:0}.muted{font-size:13px;color:var(--muted);line-height:1.5}.status-card .muted{margin:8px 0 14px}.status-card select{margin:0 0 11px;background:white}.loc-header{display:flex;align-items:center;gap:13px}.loc-header h2{font-size:16px;margin:0 0 5px}.loc-header p{margin:0}.loc-icon{display:grid;place-items:center;width:42px;height:42px;border-radius:12px;background:#e9f2fb;color:var(--blue);font-size:29px;flex-shrink:0}.toggle-row{display:flex;align-items:center;justify-content:space-between;gap:15px;border-top:1px solid var(--line);padding-top:18px;margin-top:16px;font-size:14px;font-weight:750;cursor:pointer}.toggle-row input{position:absolute;width:1px;height:1px;opacity:.01}.switch{height:26px;width:46px;border-radius:15px;background:#b0bec9;position:relative;transition:background .16s;flex-shrink:0}.switch:after{content:'';position:absolute;width:20px;height:20px;top:3px;left:3px;border-radius:50%;background:white;transition:transform .16s}.toggle-row input:checked+.switch{background:var(--green)}.toggle-row input:checked+.switch:after{transform:translateX(20px)}.small-info{font-size:12px;color:#698295;line-height:1.55;margin:11px 0 0}.section-heading{font-size:16px;font-weight:800;margin:5px 3px 12px}.tile-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.tile{min-height:135px;text-align:left;background:white;border:1px solid var(--line);border-radius:17px;box-shadow:0 5px 16px #2546690a;padding:18px 16px;display:flex;flex-direction:column;gap:9px;color:var(--ink)}.tile-icon{background:#eaf3fc;color:var(--blue);font-size:25px;width:43px;height:43px;border-radius:12px;display:grid;place-items:center}.tile b{font-size:16px}.tile small{font-size:12px;color:var(--muted)}.subbar{display:flex;justify-content:space-between;align-items:center}.subbar h2{font-size:21px;margin:6px 0 10px}.small-btn{background:white;color:var(--blue);font-size:12px;font-weight:800;border:1px solid #cbddea;padding:8px 11px;border-radius:10px}.pad{padding:15px 18px}details>summary{font-weight:800;cursor:pointer;padding:4px 0;min-height:29px}details form{margin-top:14px}.items{display:grid;gap:11px}.item-card{padding:16px}.item-card h3{font-size:16px;margin:0 0 6px}.item-card p{font-size:13px;line-height:1.55;color:#546d82;margin:7px 0}.item-top{display:flex;align-items:flex-start;justify-content:space-between;gap:10px}.pill{border-radius:6px;padding:5px 8px;background:#eaf4f0;color:var(--green);font-size:11px;font-weight:750;white-space:nowrap}.item-card details{border-top:1px solid var(--line);margin-top:12px;padding-top:12px}.item-card details summary{font-size:13px;color:var(--blue)}.item-card .btn{margin-top:11px}.summary-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.summary-cell{background:white;border:1px solid var(--line);border-radius:14px;padding:13px 8px;text-align:center}.summary-cell strong{font-size:20px;display:block}.summary-cell small{font-size:11px;color:var(--muted)}.bottom-nav{position:sticky;bottom:0;display:flex;justify-content:space-around;gap:4px;background:white;border-top:1px solid var(--line);padding:7px 8px max(10px,env(safe-area-inset-bottom));box-shadow:0 -6px 20px #25466908}.navitem{background:transparent;border:0;color:#688198;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;min-width:20%;padding:7px 8px;font-size:11px;font-weight:750;border-radius:9px}.navitem span{font-size:21px}.navitem.on{color:var(--blue);background:#e9f3fc}.footer{text-align:center;font-size:10px;color:#8ba0b0;padding:8px 0 14px}.empty{padding:24px 17px;text-align:center;border:1px dashed #cbd9e4;border-radius:12px;background:#fbfdff;color:var(--muted);font-size:13px}.sr-only{position:absolute;width:1px;height:1px;clip:rect(0,0,0,0);overflow:hidden;white-space:nowrap}
@media(min-width:740px){main{padding-top:36px}.card{padding:24px}.login-card{padding:35px}}
/* Fixed mobile navigation, including the shared discussion notification. */
.topbar{position:sticky;top:0;z-index:40;flex-shrink:0}
.top-right{min-width:108px}
.top-actions{display:flex;align-items:center;justify-content:flex-end;gap:9px}
.chat-trigger{position:relative;display:grid;place-items:center;background:#ffffff1c;color:white;border:1px solid #ffffff4d;border-radius:11px;width:38px;height:38px;padding:0;flex-shrink:0}
.chat-trigger:focus-visible{outline-color:white}
.chat-badge{position:absolute;right:-5px;top:-6px;min-width:18px;height:18px;padding:0 3px;border-radius:999px;background:#eb4a40;border:2px solid var(--navy);color:white;font-weight:800;font-size:10px;display:grid;place-items:center}
.bottom-nav{z-index:30;flex-shrink:0}
.attachment-preview{display:flex;flex-wrap:wrap;gap:7px;margin-top:9px;color:#a53737;font-size:12px}
.attachment-chip{display:flex;align-items:center;gap:7px;border:1px solid var(--line);border-radius:9px;padding:5px 9px;max-width:100%;color:var(--ink);font-size:12px;overflow-wrap:anywhere}
.attachment-chip img{width:47px;height:43px;object-fit:cover;border-radius:6px}
body.chat-open{overflow:hidden}
.chat-dialog{position:fixed;inset:0;z-index:100;background:#091b2c88;display:flex;justify-content:center;align-items:center;padding:12px}
.chat-shell{background:#f6f9fc;border:1px solid var(--line);border-radius:18px;box-shadow:0 18px 60px #0004;width:min(100%,640px);height:min(92dvh,850px);display:flex;flex-direction:column;overflow:hidden}
.chat-header{background:var(--navy);color:white;display:flex;justify-content:space-between;align-items:center;gap:10px;padding:17px 19px}
.chat-header strong{font-size:17px}.chat-header small{display:block;font-size:12px;color:#c5d9e9;margin-top:3px}
.chat-header button{background:#ffffff25;color:white;border:1px solid #ffffff4a;border-radius:10px;width:39px;height:37px;font-size:19px}
.chat-toolbar{padding:10px 13px;display:flex;gap:10px;align-items:center;justify-content:space-between;font-size:12px;color:var(--muted);border-bottom:1px solid var(--line)}
.chat-scroll{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:12px 14px}
.chat-older{display:block;margin:0 auto 14px}
.chat-messages{display:grid;gap:9px}
.chat-bubble{padding:11px 13px;background:white;border:1px solid var(--line);border-radius:13px;box-shadow:0 3px 12px #25466908}
.chat-meta{display:flex;flex-wrap:wrap;justify-content:space-between;gap:8px;font-size:12px;color:#54708a}
.chat-meta strong{color:var(--navy)}.chat-bubble p{font-size:14px;line-height:1.5;margin:8px 0 0;white-space:pre-wrap;overflow-wrap:anywhere}
.chat-compose{padding:12px 14px max(15px,env(safe-area-inset-bottom));background:white;border-top:1px solid var(--line)}
.chat-compose label{margin:0 0 5px}.chat-compose textarea{min-height:62px;margin:4px 0 9px}.chat-compose button{max-width:160px;margin-left:auto;min-height:41px;padding:9px}
@media(max-width:500px){
 .topbar{padding:11px 13px}.mark{width:34px;height:34px;border-radius:10px}.brand{font-size:19px}.brand span{font-size:16px}
 .top-right{min-width:103px}.top-actions{gap:8px}.logout{font-size:11px}
 .chat-dialog{padding:0}.chat-shell{width:100%;height:100dvh;border-radius:0;border:0}
}

/* Self-service password change: available to every mobile-only account. */
.welcome>div{flex:1;min-width:0}.welcome h1{overflow-wrap:anywhere}.password-open{white-space:nowrap;flex-shrink:0}
body.password-open{overflow:hidden}
.password-dialog{position:fixed;inset:0;z-index:120;background:#091b2c88;display:flex;align-items:center;justify-content:center;padding:15px}
.password-shell{background:white;border:1px solid var(--line);border-radius:18px;box-shadow:0 18px 60px #0004;width:min(100%,440px);max-height:calc(100dvh - 30px);overflow-y:auto;padding:22px}
.password-heading{display:flex;align-items:center;justify-content:space-between;gap:10px}
.password-heading h2{font-size:20px;line-height:1.25;margin:0}
.password-heading button{background:transparent;border:0;color:var(--muted);font-size:24px;min-width:40px;min-height:40px}
.password-shell .muted{margin:12px 0 18px}
.password-shell form label{margin:13px 0 7px}
.password-shell input{width:100%;min-height:48px;padding:12px 13px;border:1px solid #c8d7e4;border-radius:12px;margin:7px 0 0;font-size:16px}
.password-actions{display:flex;align-items:center;justify-content:flex-end;gap:10px;margin-top:15px}
.password-actions .btn{width:auto;min-height:43px;padding:10px 14px}
.password-actions .small-btn{font-size:14px;min-height:43px;padding:9px 14px}
@media(max-width:370px){.welcome{align-items:flex-start;flex-wrap:wrap}.password-open{margin-left:auto}}

/* TIOR-Mobile viewport: the page itself must never scroll beyond its content.
   Only the center panel scrolls; toolbars stay visible on every tab. */
html,body { width:100%; height:100%; max-height:100%; overflow:hidden; overscroll-behavior:none; }
.app { height:100dvh; min-height:0; max-height:100dvh; overflow:hidden; }
.topbar { position:relative; inset:auto; flex:0 0 auto; z-index:40; }
.app > main { flex:1 1 auto; min-height:0; overflow-x:hidden; overflow-y:auto;
  overscroll-behavior-y:contain; -webkit-overflow-scrolling:touch; padding-bottom:14px; }
.bottom-nav { position:relative; bottom:auto; flex:0 0 auto; z-index:30; }
.footer { flex:0 0 auto; padding:4px 0 6px; }
@media (max-width:500px) {
  .app > main { padding-top:13px; padding-bottom:10px; }
  .welcome { margin:3px 2px 14px; }
}
/* Uploaded attachments are real, directly openable files, not only a count. */
.saved-attachment-list { display:flex; flex-direction:column; gap:7px; padding:10px 0; }
.saved-attachment-btn { width:100%; border:1px solid var(--line); background:#f5faff;
  border-radius:10px; display:flex; align-items:center; gap:9px; padding:10px;
  text-align:left; color:var(--blue); font-weight:700; font-size:13px; overflow-wrap:anywhere; }
.saved-attachment-btn:disabled { opacity:.6; }
.attachment-dialog { position:fixed; inset:0; z-index:130; background:#091b2cbb;
  display:flex; align-items:center; justify-content:center; padding:12px; }
.attachment-shell { width:min(100%,720px); max-height:calc(100dvh - 24px);
  display:flex; flex-direction:column; background:white; border-radius:15px; overflow:hidden; }
.attachment-header { display:flex; justify-content:space-between; align-items:center; gap:12px; padding:12px 16px; border-bottom:1px solid var(--line); }
.attachment-header strong { font-size:14px; overflow-wrap:anywhere; }
.attachment-header button { border:0; background:transparent; font-size:24px; min-width:40px; min-height:40px; }
.attachment-body { min-height:0; overflow:auto; overscroll-behavior:contain; padding:14px; text-align:center; }
.attachment-body img { display:block; max-width:100%; max-height:calc(100dvh - 180px); width:auto; height:auto; margin:auto; object-fit:contain; }
.attachment-footer { display:flex; align-items:center; justify-content:flex-end; padding:10px 16px; border-top:1px solid var(--line); }
.attachment-footer a { display:inline-flex; align-items:center; justify-content:center; padding:10px 14px;
  min-height:42px; background:var(--blue); color:white; border-radius:10px; text-decoration:none; font-weight:800; }

.attachment-preview .attachment-selected{display:block;width:100%;font-size:13px;color:var(--green);margin:4px 0 2px}
