html:has(.stage-participant .mm-page), body.stage-participant:has(.mm-page) { overflow:clip; overscroll-behavior:none; }
body.stage-participant:has(.mm-page) { height:100vh; height:100dvh; min-height:0; }
body.stage-participant:has(.mm-page) > .sheet { display:flex; flex-direction:column; height:100%; min-height:0; }
body.stage-participant:has(.mm-page) #mast { flex:none; }
body.stage-participant #shell:has(.mm-page) { flex:1 1 0; width:100%; min-height:0; margin:0 auto; padding-block:clamp(5px,1.5dvh,16px) max(8px,env(safe-area-inset-bottom)); }
.stage-participant #content:has(> .mm-page), .mm-page { height:100%; min-height:0; }
.mm-page { --mm-wine: #550f1b; --mm-rule: #d8cbb8; --mm-ink: #3e302a; color: var(--mm-ink); width: min(1180px,100%); margin: 0 auto; }
.mm-unassigned { margin:0; }
.mm-shell { display:grid; grid-template-columns:minmax(170px,24%) minmax(0,1fr); gap:clamp(12px,2vw,26px); height:100%; min-height:0; grid-template-rows:minmax(0,1fr); }
.mm-side { min-width:0; min-height:0; overflow:auto; overscroll-behavior:contain; scrollbar-width:thin; scrollbar-color:#c9b49c transparent; }
.mm-side nav { position:relative; display:grid; gap:8px; padding:3px; }
.mm-contact { display:flex; align-items:center; gap:11px; width:100%; min-width:0; min-height:54px; padding:8px 12px; text-align:start; color:var(--mm-ink); border:1px solid var(--mm-rule); border-radius:14px; background:#fffcf7; cursor:pointer; }
.mm-contact:hover { background:#f6f0e6; }
.mm-contact[aria-pressed=true] { border-color:#936563; background:#f6ece6; color:var(--mm-wine); }
.mm-contact strong { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font:650 14px/1.25 var(--sans,Arial,sans-serif); }
.mm-mark { position:relative; display:inline-grid; overflow:hidden; flex:none; place-content:center; width:36px; height:36px; border-radius:50%; font:600 16px/1 var(--serif,Georgia,serif); background:#ecdcc5; color:#5c4229; }
.mm-mark.mm-teacher { background:#ecd8d5; color:#681b28; }
.mm-mark img { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; }
.mm-conversation { position:relative; overflow:hidden; min-width:0; min-height:0; display:grid; grid-template-rows:minmax(0,1fr) auto; border:1px solid var(--mm-rule); border-radius:18px; background:#fffcf7; }
.mm-thread { min-height:0; overflow:auto; overscroll-behavior:contain; scrollbar-width:thin; scrollbar-color:#c9b49c transparent; padding:20px clamp(16px,3vw,38px); }
.mm-day { display:flex; align-items:center; justify-content:center; gap:10px; margin:12px 0 16px; font:600 11px/1.4 var(--sans,Arial,sans-serif); color:#75634f; text-align:center; }
.mm-day:before,.mm-day:after { content:""; width:24px; height:1px; background:#d6c7af; }
.mm-day:first-child { margin-top:3px; }
.mm-line { display:flex; justify-content:flex-start; margin:8px 0; }
.mm-line.mm-own { justify-content:flex-end; }
.mm-bubble { max-width:min(77%,44ch); padding:10px 15px 8px; border:1px solid #ddcfb9; border-radius:13px 13px 13px 3px; background:#f0e8da; color:#42342b; }
.mm-own .mm-bubble { border-color:#713541; border-radius:13px 13px 3px 13px; background:#632332; color:#fffaf0; }
.mm-bubble p { margin:0; font:500 14px/1.47 var(--sans,Arial,sans-serif); white-space:pre-wrap; overflow-wrap:anywhere; }
.mm-bubble small { display:block; text-align:end; margin-top:3px; font:500 10px/1.2 var(--sans,Arial,sans-serif); color:#705d4e; }
.mm-own .mm-bubble small { color:#eed5ce; }
.mm-empty { display:grid; min-height:100%; justify-items:center; align-content:center; text-align:center; gap:7px; color:#795b47; }
.mm-empty svg { width:31px; height:31px; margin-bottom:4px; color:var(--mm-wine); }
.mm-empty strong { font:600 22px/1.15 var(--serif,Georgia,serif); }
.mm-empty p { margin:0; font:500 13px/1.45 var(--sans,Arial,sans-serif); }
.mm-compose { padding:12px clamp(14px,2.2vw,24px) 10px; }
.mm-compose-row { display:flex; align-items:end; gap:7px; padding:5px; border:1px solid #c9bba8; border-radius:18px; background:#fffdf8; }
.mm-compose-row:focus-within { border-color:#8b5653; box-shadow:0 0 0 1px #8b5653; }
.mm-compose textarea { flex:1 1 auto; border:none; background:transparent; resize:vertical; padding:6px 8px; width:100%; min-width:0; max-height:100px; min-height:35px; height:35px; outline:none; font:500 14px/1.45 var(--sans,Arial,sans-serif); color:#392c26; }
.mm-compose button,.mm-new { display:grid; flex:none; place-content:center; width:36px; height:36px; padding:0; border:1px solid #74333e; border-radius:50%; background:var(--mm-wine); color:#fff6e5; cursor:pointer; }
.mm-compose button:disabled { color:#8c7366; background:#eadfd0; border-color:#d9caba; cursor:default; }
.mm-compose button svg { width:19px; height:19px; }
.mm-foot { display:flex; align-items:center; justify-content:space-between; gap:6px; min-height:18px; padding-top:5px; font:500 10px/1.35 var(--sans,Arial,sans-serif); color:#71614f; }
.mm-feedback { text-align:end; color:#7b2834; }
.mm-locked { min-height:0; overflow:auto; display:grid; align-content:center; justify-items:center; padding:20px; grid-row:1/-1; text-align:center; }
.mm-locked>div { display:grid; justify-items:center; gap:12px; max-width:37ch; }
.mm-locked svg { width:34px; height:34px; color:var(--mm-wine); }
.mm-locked h3 { margin:0; color:var(--mm-wine); font:600 clamp(23px,3vw,32px)/1.12 var(--serif,Georgia,serif); }
.mm-locked p,.mm-readonly p { margin:0; color:#665247; font:500 14px/1.45 var(--sans,Arial,sans-serif); }
.mm-readonly { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:9px; padding:13px 20px; border-top:1px solid var(--mm-rule); background:#f8f0e2; }
.mm-readonly .btn,.mm-locked .btn { min-height:36px; height:auto; padding:8px 14px; font-size:13px; }
.mm-new { position:absolute; right:18px; bottom:85px; z-index:1; }
.mm-new svg { width:19px; height:19px; }
.mm-page [hidden] { display:none!important; }
.mm-page :is(button,a,.mm-thread):focus-visible { outline:2px solid #997445; outline-offset:2px; }
@media(max-width:700px){
 .mm-shell { grid-template-columns:minmax(0,1fr); grid-template-rows:auto minmax(0,1fr); gap:8px; }
 .mm-side { --mm-row-height:44px; max-height:calc(3 * var(--mm-row-height) + 10px); }
 .mm-side nav { gap:5px; }
 .mm-contact { width:100%; height:var(--mm-row-height); min-height:var(--mm-row-height); padding:5px 10px 5px 6px; gap:7px; border-radius:12px; }
 .mm-contact .mm-mark { width:31px; height:31px; font-size:13px; }
 .mm-thread { padding:13px 12px; }.mm-bubble { max-width:85%; padding:8px 11px 6px; }
 .mm-compose { padding:9px 9px 6px; }.mm-compose textarea { font-size:16px; }
}
.mm-info { position:relative; }
.mm-mode { display:inline-flex; align-items:center; gap:5px; cursor:pointer; list-style:none; }
.mm-mode::-webkit-details-marker { display:none; }
.mm-mode:after { content:""; border:solid currentColor; border-width:0 1px 1px 0; width:4px; height:4px; transform:rotate(45deg); }
.mm-info[open] .mm-mode:after { transform:rotate(225deg); }
.mm-mode-help { position:absolute; z-index:2; left:0; bottom:100%; width:min(260px,65vw); margin:0 0 6px; padding:10px; border:1px solid var(--mm-rule); border-radius:8px; color:var(--mm-ink); background:#fffaf1; font:500 12px/1.45 var(--sans,Arial,sans-serif); }
.mm-compose .mm-support-team { display:inline-flex; align-items:center; width:auto; height:auto; min-height:32px; padding:4px 6px; border:0; border-radius:4px; background:transparent; color:inherit; text-decoration:underline; font:inherit; }
.mm-support-author { display:block; margin-bottom:2px; font:600 11px/1.4 var(--sans,Arial,sans-serif); }
.mm-foot a { color:var(--mm-wine); }

[data-member-presence]:not(:empty) { display:inline-flex; align-items:center; gap:.4em; font:500 12px/1.35 var(--sans,Arial,sans-serif); }
[data-member-presence]:not(:empty)::before { content:''; width:.55em; height:.55em; border:1px solid currentColor; border-radius:50%; flex:none; }
[data-member-presence][data-presence-state="online"]::before { border-color:#3b6747; background:#4f835d; }
.mm-contact-label { display:grid; gap:3px; min-width:0; text-align:start; }
.mm-contact-label [data-member-presence] { color:var(--mm-muted,#64584d); }


.mm-side {
  background:transparent;
  mask-image:linear-gradient(to bottom,transparent,#000 var(--mm-fade-top,0px),#000 calc(100% - var(--mm-fade-bottom,0px)),transparent);
}
.mm-contact { position:relative; box-shadow:inset 0 1px #fffefa,0 3px 8px -6px #55392955; }
@media(max-width:700px){
  .mm-side { mask-image:none; }
  .mm-contact { box-shadow:none; }
  .mm-contact-label { gap:1px; }
  .mm-contact-label [data-member-presence] { font-size:10px; line-height:1.15; }
  .mm-contact[aria-pressed=true] { box-shadow:inset 0 0 0 1px #936563; }
}
@media(max-width:700px) and (max-height:450px){
  .mm-side { --mm-row-height:36px; }
  .mm-contact { padding-block:2px; }
  .mm-contact .mm-mark { width:28px; height:28px; }
}
