.leon-role-dashboard{position:fixed;inset:0;z-index:22000;display:grid;grid-template-columns:238px minmax(0,1fr);background:#f7f4ee;color:#302820;font:15px/1.55 Arial,Helvetica,sans-serif;overflow:hidden;box-sizing:border-box}
.leon-role-dashboard *,.ld-modal *{box-sizing:border-box}.leon-role-dashboard [hidden],.ld-modal [hidden]{display:none!important}
.ld-sidebar{background:linear-gradient(155deg,#49382b,#614632);color:#fffaf5;padding:28px 18px;overflow:auto;display:flex;flex-direction:column;gap:12px}.ld-brand{display:grid;grid-template-columns:48px 1fr;column-gap:9px;align-items:center;padding:0 8px 26px}.ld-brand img{grid-row:1/3;width:46px;height:54px;object-fit:contain}.ld-brand strong{font:700 28px Georgia,serif}.ld-brand small{font-size:10px;letter-spacing:.6px}.ld-sidebar>p{padding:0 10px;opacity:.75;font-size:13px}.ld-sidebar nav{display:flex;flex-direction:column;gap:9px}.leon-role-dashboard .ld-sidebar button{background:transparent!important;color:white!important;border-color:transparent!important;text-align:left;padding:12px 14px!important;border-radius:9px!important;white-space:normal}.leon-role-dashboard .ld-sidebar button:hover{background:#ffffff18!important}.ld-sidebar nav button:nth-last-child(2){margin-top:28px}
.ld-content{min-width:0;overflow-y:auto;padding:30px clamp(18px,3vw,42px);overscroll-behavior:contain}.ld-header{margin:0 0 26px;display:block}.ld-header h1{font:700 clamp(26px,3.2vw,38px)/1.2 Georgia,serif;color:#49382b;margin:0 0 7px}.ld-header p{margin:0;color:#735e4d}.ld-status:empty{display:none}.ld-status{padding:12px 16px;background:#fff;border-left:3px solid #9b7757;border-radius:6px;margin:12px 0;white-space:pre-wrap}
.leon-role-dashboard button,.ld-modal button{width:auto!important;min-width:0!important;max-width:100%;background:#49382b!important;color:#fff!important;border:1px solid #49382b!important;border-radius:8px!important;box-shadow:none!important;min-height:40px;padding:9px 16px!important;font:600 14px/1.4 Arial,sans-serif!important;cursor:pointer;margin:0!important;white-space:nowrap}.leon-role-dashboard button:hover,.ld-modal button:hover{background:#70513a!important}.leon-role-dashboard button:focus-visible,.ld-modal button:focus-visible,.leon-role-dashboard input:focus-visible,.leon-role-dashboard select:focus-visible{outline:3px solid #9b7757;outline-offset:3px}.leon-role-dashboard button:disabled,.ld-modal button:disabled{opacity:.55;cursor:wait}.leon-role-dashboard button.ld-secondary,.ld-modal button.ld-secondary{background:#fff!important;color:#49382b!important;border-color:#d7c7b9!important}.leon-role-dashboard button.ld-secondary:hover,.ld-modal button.ld-secondary:hover{background:#f4ebe1!important}.leon-role-dashboard button[aria-pressed=true]{background:#eee1d2!important;color:#49382b!important;border-color:#9b7757!important}
.ld-panel{background:#fff;border:1px solid #e7dfd4;border-radius:14px;padding:22px;box-shadow:0 4px 18px #49382b08;margin-bottom:20px;min-width:0}.ld-panel h2{font:700 23px Georgia,serif;color:#49382b;margin:0 0 18px}.ld-toolbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-bottom:16px}.ld-toolbar:last-child{margin-bottom:0}.leon-role-dashboard input,.leon-role-dashboard select,.ld-modal input:not([type=checkbox]),.ld-modal select{width:auto;min-width:140px;max-width:100%;padding:10px 13px;border:1px solid #ded5cb;background:#fff;color:#302820;border-radius:8px;font:15px Arial,sans-serif;min-height:42px;margin:0}.ld-toolbar input[type=search]{flex:1;min-width:190px}.ld-toolbar select{flex:0 1 170px}.ld-table-scroll{width:100%;overflow-x:auto}.leon-role-dashboard table{width:100%;border-collapse:collapse;margin:0;table-layout:auto;white-space:normal;background:white}.leon-role-dashboard th{background:#f6ede3;color:#49382b;text-align:left;padding:12px 14px;border:0;border-bottom:1px solid #e7dfd4;font-size:13px;font-weight:700}.leon-role-dashboard td{padding:15px 14px;border:0;border-bottom:1px solid #eee7df;vertical-align:middle;font-size:14px}.leon-role-dashboard td:first-child{font-weight:650;min-width:160px}.leon-role-dashboard td .ld-toolbar{gap:6px;margin:0;flex-wrap:nowrap}.leon-role-dashboard td button{padding:7px 11px!important;min-height:35px;font-size:13px!important}.ld-table-scroll+ .ld-toolbar{margin-top:16px}.ld-badge{display:inline-block;border-radius:20px;padding:5px 11px;font-size:12px;line-height:1.3;background:#f5eadd;color:#735438;white-space:nowrap}.ld-badge.done{background:#eaf2ec;color:#42765a}.ld-badge.doing{background:#eee9e2;color:#49382b}.ld-badge.todo{background:#fbefeb;color:#a54d3e}
.ld-tabs{display:flex;gap:8px;border-bottom:1px solid #e7dfd4;margin:12px 0 20px;padding-bottom:12px;flex-wrap:wrap}.ld-tabs button{border-radius:7px!important}.ld-stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr);gap:16px;margin-bottom:24px}.ld-stats section{background:#fff;border:1px solid #e7dfd4;border-radius:13px;padding:20px 22px;box-shadow:0 3px 12px #49382b06;min-width:0}.ld-stats strong{display:block;font:700 31px Georgia,serif;color:#49382b;margin-bottom:5px}.ld-stats span{font-size:13px;color:#735e4d}.ld-class-layout{display:grid;grid-template-columns:250px minmax(0,1fr);align-items:start;gap:20px}.ld-class-layout>.ld-panel:first-child{display:flex;flex-direction:column;gap:10px}.ld-class-layout>.ld-panel:first-child button{white-space:normal;text-align:left}.ld-class-layout>.ld-panel:first-child small{overflow-wrap:anywhere}
.ld-modal{position:fixed;inset:0;z-index:24000;background:#30282080;padding:24px;display:flex;align-items:center;justify-content:center;color:#302820;font:15px/1.55 Arial,sans-serif}.ld-modal-card{background:#fffdf9;border:1px solid #e7dfd4;border-radius:16px;padding:26px;width:min(680px,100%);max-height:90vh;overflow:auto;box-shadow:0 20px 80px #30282033}.ld-modal-card>h2{font:700 26px Georgia,serif;margin:0 0 14px;color:#49382b}.ld-modal-card>button{float:right}.ld-modal-card>div{clear:both;padding-top:12px}.ld-modal-card>p{color:#735438;white-space:pre-wrap}.ld-modal label{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:12px 0}.ld-modal label input:not([type=checkbox]){width:100%}.ld-modal input[type=checkbox]{width:18px;height:18px;accent-color:#49382b}.ld-modal details{border:1px solid #e7dfd4;padding:14px;border-radius:9px;margin:16px 0}.ld-modal summary{cursor:pointer;font-weight:650}.ld-modal .ld-toolbar{margin-top:16px}.ld-modal-card button+button{margin:8px!important}.ld-modal-card div>button{margin:4px 6px 4px 0!important}
/* Compact existing detail/editor surfaces; preserve all handlers and controls. */
.leon-dialog-page:not(.leon-role-dashboard){font-family:Arial,sans-serif;background:#f7f4ee!important;color:#302820}.leon-dialog-page:not(.leon-role-dashboard)>main{max-width:1180px;margin:auto}.leon-dialog-page:not(.leon-role-dashboard) button{width:auto!important;display:inline-flex;max-width:100%;padding:9px 14px!important;margin:6px 8px 6px 0!important;min-height:38px;border-radius:8px!important;font-size:14px!important}.leon-dialog-page:not(.leon-role-dashboard)>h2,.leon-dialog-page:not(.leon-role-dashboard)>p{max-width:1180px;margin:16px auto}.leon-dialog-page input,.leon-dialog-page select,.leon-dialog-page textarea{border-radius:8px;border:1px solid #e7dfd4}
@media(max-width:1150px){.leon-role-dashboard{grid-template-columns:200px minmax(0,1fr)}.ld-class-layout{grid-template-columns:190px minmax(0,1fr)}.ld-stats{grid-template-columns:repeat(2,minmax(0,1fr))}.ld-panel{padding:17px}.ld-content{padding:24px 18px}}
@media(max-width:780px){.leon-role-dashboard{grid-template-columns:minmax(0,1fr);grid-template-rows:auto minmax(0,1fr)}.ld-sidebar{padding:12px 16px;overflow:visible;display:block}.ld-brand{display:block;padding:0}.ld-brand img,.ld-brand small,.ld-sidebar>p{display:none}.ld-brand strong{font-size:21px}.ld-sidebar nav{display:flex;flex-direction:row;overflow-x:auto;gap:6px;margin-top:10px}.leon-role-dashboard .ld-sidebar button{flex:0 0 auto;margin-top:0!important;padding:8px 10px!important;font-size:12px!important}.ld-content{padding:20px 14px}.ld-class-layout{grid-template-columns:minmax(0,1fr)}.ld-class-layout>.ld-panel:first-child{display:flex;flex-direction:row;overflow:auto;flex-wrap:wrap}.ld-class-layout>.ld-panel:first-child h2{width:100%}.ld-stats{gap:10px}.ld-stats section{padding:16px}.ld-modal{padding:12px}.ld-modal-card{padding:18px}.ld-toolbar input[type=search]{min-width:140px;width:100%}.ld-toolbar select{flex:1 1 140px}.leon-role-dashboard td,.leon-role-dashboard th{padding:11px 10px}.ld-header{margin-bottom:20px}}
.leon-role-dashboard .ld-header{margin-bottom:16px;padding:0}
.leon-role-dashboard .ld-header h1{font-size:clamp(25px,2.6vw,32px);margin-bottom:4px}
.leon-role-dashboard .ld-header p{font-size:14px;line-height:1.45}
.leon-role-dashboard .ld-brand{grid-template-columns:70px minmax(0,1fr);column-gap:10px;padding:0 0 18px;align-items:center}
.leon-role-dashboard .ld-brand img{width:70px;height:76px;object-fit:contain;align-self:center;justify-self:center;margin:0;max-width:100%}
.leon-role-dashboard .ld-brand strong{font-size:27px;line-height:1.1;align-self:end}
.leon-role-dashboard .ld-brand small{font-size:9px;line-height:1.4;align-self:start;letter-spacing:.3px}
.leon-role-dashboard .ld-table-scroll{overflow-x:auto;-webkit-overflow-scrolling:touch}
.leon-role-dashboard table{min-width:760px}
.leon-role-dashboard th{white-space:nowrap}
.leon-role-dashboard td:first-child{min-width:210px;max-width:340px;overflow-wrap:break-word;word-break:normal;line-height:1.5}
.leon-role-dashboard td:not(:first-child){white-space:nowrap}
.leon-role-dashboard td:last-child{width:1%;white-space:nowrap}
.leon-role-dashboard td .ld-toolbar{flex-wrap:wrap;min-width:130px}
.leon-role-dashboard .ld-class-layout{grid-template-columns:210px minmax(0,1fr);gap:16px}
.leon-role-dashboard .ld-stats{gap:12px;margin-bottom:18px}
.leon-role-dashboard .ld-stats section{padding:15px 18px}
.leon-role-dashboard .ld-stats strong{font-size:28px}
.leon-role-dashboard .ld-toolbar{gap:8px}
.leon-role-dashboard .ld-toolbar button{padding:8px 13px!important;min-height:38px}
@media(max-width:1150px) and (min-width:781px){.leon-role-dashboard .ld-class-layout{grid-template-columns:170px minmax(0,1fr)}.leon-role-dashboard .ld-brand{grid-template-columns:58px minmax(0,1fr)}.leon-role-dashboard .ld-brand img{width:58px;height:68px}.leon-role-dashboard .ld-brand strong{font-size:23px}}
@media(max-width:780px){.leon-role-dashboard .ld-class-layout{grid-template-columns:minmax(0,1fr)}.leon-role-dashboard .ld-brand{display:flex;gap:10px;padding:0;align-items:center}.leon-role-dashboard .ld-brand img{display:block;width:40px;height:42px}.leon-role-dashboard .ld-brand strong{font-size:23px;align-self:center}.leon-role-dashboard .ld-brand small{display:none}.leon-role-dashboard .ld-header{margin-bottom:14px}.leon-role-dashboard .ld-panel{padding:14px}.leon-role-dashboard .ld-toolbar button{min-height:42px}}


.leon-role-dashboard .ld-table-scroll :is(th,td:not(:first-child),button){
 writing-mode:horizontal-tb;white-space:nowrap!important;word-break:normal;overflow-wrap:normal;
}
.leon-role-dashboard .ld-table-scroll button{flex:0 0 auto;min-inline-size:max-content;max-inline-size:none}
.leon-role-dashboard .ld-table-scroll td .ld-toolbar{flex-wrap:wrap;min-inline-size:145px}

.ld-class-code{display:flex;flex-wrap:wrap;align-items:center;gap:6px;margin:8px 0}
.leon-role-dashboard .ld-class-code{width:100%}
.leon-role-dashboard .ld-class-code input,.ld-class-code input{min-width:0;width:8ch;text-align:center;letter-spacing:.12em}
.leon-role-dashboard .ld-class-code button,.ld-class-code button{white-space:nowrap;max-width:none}
.ld-class-code [role=status]{flex-basis:100%;font-size:.88em}
.leon-member-actions{display:flex;flex-wrap:wrap;gap:6px;width:max-content}
.leon-member-actions button,.leon-role-dashboard .ld-table-scroll th,.leon-role-dashboard .ld-table-scroll button{white-space:nowrap!important;word-break:normal!important;overflow-wrap:normal!important;writing-mode:horizontal-tb!important}

.leon-role-dashboard .ld-table-scroll{max-width:100%;min-width:0}
.leon-role-dashboard .ld-table-scroll .ld-action-cell{min-width:9rem;width:1%}
.leon-role-dashboard .ld-table-scroll button,
.leon-dialog-page:not(.leon-role-dashboard) table button{
 display:inline-flex;align-items:center;justify-content:center;
 flex:0 0 auto;min-width:max-content!important;max-width:none!important;
 white-space:nowrap!important;word-break:normal!important;overflow-wrap:normal!important;
 writing-mode:horizontal-tb!important;
}
.ld-row-actions{display:flex;align-items:center;gap:8px}
.ld-exam-picker{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,16rem),1fr));gap:12px;margin:12px 0}
.ld-exam-picker section{display:flex;flex-direction:column;align-items:stretch;gap:6px;min-width:0}
.ld-exam-picker h4{margin:0 0 4px}
.leon-role-dashboard .ld-exam-picker button{white-space:normal;text-align:left;overflow-wrap:break-word}
.leon-role-dashboard .ld-exam-picker button[aria-pressed=true]{outline:2px solid #614632;outline-offset:-2px}

/* Both the role dashboard and the existing class/result dialogs use scrollable tables. */
.leon-dialog-page .ld-table-scroll{display:block;max-width:100%;min-width:0;overflow-x:auto;-webkit-overflow-scrolling:touch}
.leon-dialog-page .ld-table-scroll table{table-layout:auto}
.leon-dialog-page .ld-table-scroll th,
.leon-dialog-page .ld-table-scroll .ld-action-cell{white-space:nowrap!important;word-break:normal!important;overflow-wrap:normal!important}
.leon-dialog-page .ld-table-scroll th{min-width:6.5rem}
.leon-dialog-page .ld-table-scroll .ld-action-cell{min-width:9rem}
.leon-dialog-page .ld-table-scroll button{flex-shrink:0;min-width:max-content!important;writing-mode:horizontal-tb!important;white-space:nowrap!important}
.leon-dialog-page input:is([type=checkbox],[type=radio]){flex:0 0 auto;width:1rem!important;min-width:1rem!important;height:1rem;vertical-align:middle;padding:0!important}
[data-assignment-wizard] label:has(input[type=checkbox]){display:flex;align-items:center;gap:.5rem}

/* Keep action labels and their intrinsic widths together in WebKit tables. */
.leon-role-dashboard .ld-table-scroll,
.leon-dialog-page .ld-table-scroll{width:100%;max-width:100%;overflow:auto}
.leon-role-dashboard .ld-table-scroll table,
.leon-dialog-page .ld-table-scroll table{table-layout:auto!important}
.leon-role-dashboard .ld-table-scroll :is(th,td)[data-column=due]{min-width:10rem}
.leon-role-dashboard .ld-table-scroll :is(th,td)[data-column=duration],
.leon-role-dashboard .ld-table-scroll :is(th,td)[data-column=submitted]{min-width:7rem}
.leon-role-dashboard .ld-table-scroll :is(th,td)[data-column=actions]{min-width:11rem}
.leon-role-dashboard .ld-table-scroll .ld-action-cell :is(.ld-toolbar,.ld-row-actions),
.leon-dialog-page .ld-table-scroll .leon-member-actions{display:inline-flex;flex-wrap:nowrap;width:max-content;min-width:max-content}
.leon-role-dashboard .ld-table-scroll button.ld-action,
.leon-dialog-page .ld-table-scroll .ld-action-cell button{
 display:inline-block!important;flex:0 0 auto!important;
 width:max-content!important;min-width:max-content!important;max-width:none!important;
 white-space:nowrap!important;word-break:normal!important;overflow-wrap:normal!important;
 writing-mode:horizontal-tb!important;letter-spacing:normal;
}

.leon-role-dashboard .ld-table-scroll table{
 width:100%;min-width:0;table-layout:auto!important;
}
.leon-role-dashboard .ld-table-scroll :is(th,td){
 padding:8px 10px;vertical-align:middle;line-height:1.35;
}
.leon-role-dashboard .ld-table-scroll td:first-child{
 min-width:10rem;max-width:19rem;word-break:normal;overflow-wrap:break-word;
}
.leon-role-dashboard .ld-table-scroll :is(th,td)[data-column=duration]{min-width:5.5rem}
.leon-role-dashboard .ld-table-scroll :is(th,td)[data-column=due]{min-width:7.5rem}
.leon-role-dashboard .ld-table-scroll .ld-action-cell :is(.ld-toolbar,.ld-row-actions){
 gap:5px;margin:0;min-width:0;
}
.leon-role-dashboard .ld-table-scroll .ld-action-cell button{
 min-height:34px;padding:5px 9px!important;
}
.ld-assignment-status{display:grid;justify-items:start;gap:3px}
.ld-assignment-status small{font-size:.8rem;white-space:nowrap}
.ld-assignment-due{white-space:nowrap;font-variant-numeric:tabular-nums}
@media(max-width:780px){
 .leon-role-dashboard .ld-table-scroll td:first-child{min-width:8.5rem}
 .leon-role-dashboard .ld-table-scroll .ld-action-cell button{min-height:44px}
}

/* Keep action labels horizontal in every dashboard and result table. */
.ld-table-scroll .ld-action-cell,.ld-table-scroll .ld-row-actions{
 white-space:nowrap!important;word-break:normal!important;overflow-wrap:normal!important;
}
.ld-table-scroll .ld-action-cell button,.ld-table-scroll .ld-row-actions button{
 flex:0 0 auto!important;width:max-content!important;min-width:max-content!important;
 max-width:none!important;white-space:nowrap!important;word-break:normal!important;
 overflow-wrap:normal!important;writing-mode:horizontal-tb!important;
}

/* Speaking preflight is separate from the live examiner. */
.leon-mic-preflight{
 width:min(100%,40rem);margin:14px auto;padding:clamp(12px,3vw,20px);
 border:1px solid #e7dfd4;border-radius:14px;background:#fff;box-sizing:border-box;
}
.leon-mic-preflight h3{margin:0 0 8px;color:#49382b}
.leon-mic-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.leon-dialog-page .leon-mic-actions .speaking-start{
 background:#49382b!important;color:#fff!important;font-weight:700;
 min-height:44px!important;margin-right:0!important;
}
.leon-mic-preflight details{margin-top:10px;color:#614632}
.leon-mic-preflight .leon-mic-trial-compact{margin:8px 0!important;padding:8px 12px!important}
.leon-mic-trial-compact h4{display:none}
.leon-mic-trial-compact p{margin:4px 0}
.leon-mic-trial-compact audio,.leon-mic-trial-compact progress{display:block;width:100%;max-width:100%}
.leon-mic-trial-compact audio:not([src]){display:none}

/* Preserve short metadata while allowing descriptive titles to wrap. */
.ld-table-scroll table :is(th,td):is([data-column=skill],[data-column=program],[data-column=duration],[data-column=due],[data-column=submitted],[data-column=when]){
 white-space:nowrap;
 word-break:normal;
 overflow-wrap:normal;
}
.ld-table-scroll table :is(th,td)[data-column=title]{
 word-break:normal;
 overflow-wrap:break-word;
}
