@font-face{
  font-family:"DIN Next LT Arabic";
  src:url("assets/fonts/DINNextLTArabic-Regular.ttf") format("truetype");
  font-style:normal;font-weight:400;font-display:swap;
}
:root{
  --blue:#00416B;--deep:#002343;--green:#00C08B;--green-dark:#008661;
  --text:#2F3B3E;--text-2:#4D5858;--muted:#6C787A;--line:#D4DEE0;--line-strong:#B8C6C9;
  --surface:#FFFFFF;--soft:#F7FAFA;--blue-soft:#EAF1F5;--success-soft:#E6F9F4;
  --error:#D02C2F;--error-soft:#FBEAEA;--warning:#B47A00;--warning-soft:#FFF8E8;
  --label:14px;--body:16px;--subtitle:20px;--heading:24px;--display:32px;
  --font:"DIN Next LT Arabic","DIN Next","DINNextLTArabic","Helvetica Neue",Arial,sans-serif;
  --shadow:0 18px 52px rgba(0,35,67,.22);
}
*{box-sizing:border-box}
html,body{margin:0;width:100%;min-height:100%;font-family:var(--font);color:var(--text);background:#fff;-webkit-font-smoothing:antialiased}
body{overflow-x:hidden}button{font:inherit}h1,h2,h3,p{margin:0}
/* keep the already-approved Elham/Rise shell unchanged */
.app-shell{width:100%;min-height:680px;padding:12px;background:#fff;display:flex;justify-content:center;align-items:stretch}
.activity-frame{width:min(1440px,100%);height:656px;border:1px solid var(--line);border-radius:16px;background:var(--soft);overflow:hidden;display:flex;flex-direction:column;position:relative}
.screen{height:100%;min-height:0;display:flex;flex-direction:column}
.btn{height:48px;min-width:118px;padding:0 20px;border-radius:12px;border:1px solid transparent;font-size:var(--body);font-weight:700;display:inline-flex;align-items:center;justify-content:center;cursor:pointer;white-space:nowrap}
.btn.primary{background:var(--green);color:#fff}.btn.primary:hover{background:var(--green-dark)}
.btn.secondary{background:#fff;color:var(--blue);border-color:var(--blue)}.btn.secondary:hover{background:var(--blue-soft)}
.btn:disabled{background:#F2F5F5!important;color:#97A4A6!important;border-color:#DCE4E6!important;cursor:not-allowed;pointer-events:none}
.btn:focus-visible,.option-card:focus-visible,.composer-trigger:focus-visible,.sheet-option:focus-visible,.close-btn:focus-visible{outline:3px solid rgba(0,192,139,.22);outline-offset:2px}
/* START — same visual template as T-EPA3 Activity 2 */
.start-screen{display:grid;grid-template-columns:minmax(420px,48%) minmax(0,52%);background:#fff}
.start-copy{padding:56px 48px 56px 56px;display:flex;flex-direction:column;justify-content:center;align-items:flex-start;gap:16px;min-width:0}
.start-copy h1{font-size:var(--display);line-height:1.18;color:var(--blue);font-weight:700;max-width:560px}
.start-copy p{font-size:var(--body);line-height:1.5;color:var(--text-2);max-width:540px}.start-copy .btn{margin-top:8px}
.start-art{display:flex;align-items:center;justify-content:center;padding:40px 48px 40px 8px;overflow:hidden;background:#fff}
.start-art img{display:block;width:min(92%,780px);max-width:100%;height:auto;max-height:560px;object-fit:contain}
/* INSTRUCTIONS */
.instructions-screen{display:grid;grid-template-rows:minmax(0,1fr) 80px;background:var(--soft)}
.instructions-main{padding:40px 48px 24px;display:flex;align-items:center;justify-content:center;min-height:0}
.instructions-wrap{width:min(1100px,100%);margin:0 auto}.instructions-heading h1{font-size:var(--display);line-height:1.18;color:var(--blue);font-weight:700}
.instructions-heading p{font-size:var(--body);line-height:1.5;color:var(--text-2);margin-top:12px;max-width:900px}
.instruction-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin-top:24px}
.instruction-card{background:#fff;border:1px solid var(--line);border-radius:16px;padding:24px;min-height:220px;display:flex;flex-direction:column;gap:14px;min-width:0}
.instruction-icon{width:48px;height:48px;display:flex;align-items:center;justify-content:center;color:var(--blue)}
.instruction-icon svg{width:48px;height:48px;fill:none;stroke:currentColor;stroke-width:2.1;stroke-linecap:round;stroke-linejoin:round}.instruction-icon .accent{stroke:var(--green)}
.instruction-card h2{font-size:var(--subtitle);line-height:1.2;color:var(--deep);font-weight:700}.instruction-card p{font-size:var(--body);line-height:1.5;color:var(--text-2)}
.instruction-note{margin-top:16px;border-left:4px solid var(--green);background:#fff;padding:13px 16px;border-radius:0 12px 12px 0;font-size:var(--body);line-height:1.5;color:var(--text)}
.simple-rail{height:80px;border-top:1px solid var(--line);background:#fff;padding:14px 18px;display:grid;grid-template-columns:1fr minmax(0,auto) 1fr;align-items:center}.simple-rail .btn{grid-column:3;justify-self:end}
/* SHARED TASK SHELL / PROGRESS — copied from reference visual grammar */
.activity{display:grid;grid-template-rows:82px minmax(0,1fr) 76px;background:var(--soft)}
.task-header{padding:14px 24px;border-bottom:1px solid var(--line);background:#fff;display:flex;align-items:center;justify-content:space-between;gap:24px}
.task-title{min-width:0}.task-title h1{font-size:var(--heading);line-height:1.18;color:var(--blue);font-weight:700}.task-title p{font-size:var(--label);line-height:1.35;color:var(--muted);margin-top:5px}
.progress{display:flex;align-items:center;gap:12px;flex:0 0 auto}.progress strong{font-size:var(--label);line-height:1.35;color:var(--text-2);font-weight:500;white-space:nowrap}
.progress-track{width:180px;height:8px;background:var(--line);border-radius:999px;overflow:hidden}.progress-fill{height:100%;background:var(--green);border-radius:999px}
.content{min-height:0;padding:12px 14px;background:var(--soft);display:flex;justify-content:center;overflow:hidden}
.action-rail{border-top:1px solid var(--line);background:#fff;padding:14px 18px;display:grid;grid-template-columns:1fr minmax(0,auto) 1fr;align-items:center;gap:16px}
.action-left{justify-self:start}.action-center{justify-self:center;text-align:center;font-size:var(--label);line-height:1.35;color:var(--muted)}.action-right{justify-self:end}
/* CONVERSATION */
.conversation-layout{width:min(1140px,100%);height:100%;min-height:0}
.conversation-card{position:relative;background:#fff;border:1px solid var(--line);border-radius:16px;min-height:0;height:100%;overflow:hidden;display:grid;grid-template-rows:auto minmax(0,1fr) auto}
.conversation-head{padding:10px 16px;border-bottom:1px solid var(--line);background:#fff;display:flex;align-items:flex-start;justify-content:space-between;gap:16px}
.conversation-head-copy{min-width:0}.task-kicker{font-size:var(--label);line-height:1.35;color:var(--green-dark);font-weight:700;text-transform:uppercase;letter-spacing:.2px}
.conversation-head h2{font-size:var(--subtitle);line-height:1.22;color:var(--blue);font-weight:700;margin-top:2px}.conversation-head p{font-size:var(--body);line-height:1.42;color:var(--muted);margin-top:3px}.conversation-count{font-size:var(--label);line-height:1.35;color:var(--text-2);white-space:nowrap}
.chat-window{min-height:0;overflow:auto;padding:12px 18px 14px;background:#F8FAFA;display:flex;flex-direction:column;gap:10px;scrollbar-width:thin}
.chat-row{display:flex;gap:10px;align-items:flex-end}.chat-row.trainee{justify-content:flex-start}.chat-row.educator,.chat-row.master{justify-content:flex-end}.chat-row.assessor{justify-content:flex-start}
.chat-bubble{max-width:74%;border:1px solid #C9D8DC;border-radius:18px;padding:11px 14px;font-size:var(--body);line-height:1.46;color:var(--text);background:#fff}
.educator .chat-bubble,.master .chat-bubble{background:#EAF7F3;border-color:#B4DDCF}.assessor .chat-bubble{background:var(--warning-soft);border-color:#E8D6AA}
.speaker{display:block;font-size:var(--label);line-height:1.35;font-weight:700;color:var(--blue);margin-bottom:4px}.educator .speaker,.master .speaker{color:var(--green-dark)}.assessor .speaker{color:#7A5200}
.avatar{width:40px;height:40px;min-width:40px;min-height:40px;flex:0 0 40px;aspect-ratio:1/1;border-radius:50%;background:var(--blue-soft);border:1px solid #D9E4E6;overflow:hidden;display:grid;place-items:center;color:var(--blue);font-size:12px;font-weight:700;line-height:1}
.avatar.educator-avatar,.avatar.master-avatar{background:var(--success-soft);color:var(--green-dark)}.avatar.assessor-avatar{background:var(--warning-soft);color:#7A5200}
.chat-row.message-enter{opacity:0;transform:translateY(8px);animation:chatMessageIn .34s ease-out forwards;animation-delay:var(--message-delay,0ms)}@keyframes chatMessageIn{to{opacity:1;transform:translateY(0)}}
.conversation-foot{border-top:1px solid var(--line);background:#fff;padding:10px 16px;font-size:var(--label);line-height:1.4;color:var(--muted)}
/* COMPOSER — same conversational reply pattern as T-EPA3 Activity 2 */
.composer-bar{border-top:1px solid var(--line);background:#fff;padding:10px 14px}.composer-trigger{width:100%;min-height:54px;border:1.5px solid #B7C8CC;border-radius:14px;background:#fff;padding:9px 14px;display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:12px;align-items:start;text-align:left;cursor:pointer;color:var(--text)}
.composer-trigger:hover{border-color:var(--blue);background:#FBFCFC}.composer-trigger.has-selection{border-color:#9EDDCB;background:#F4FCF9}.composer-label{font-size:var(--label);font-weight:700;color:var(--blue);white-space:nowrap}.composer-preview{font-size:var(--body);line-height:1.35;color:var(--muted);white-space:normal;overflow-wrap:break-word;padding-top:1px}.composer-trigger.has-selection .composer-preview{color:var(--text)}.composer-chevron{width:34px;height:34px;border-radius:10px;background:var(--blue-soft);display:grid;place-items:center;color:var(--blue);font-size:18px;line-height:1;align-self:center}
.composer-scrim{position:absolute;inset:0;background:rgba(0,35,67,.12);z-index:20;cursor:pointer}.composer-sheet{position:absolute;left:0;right:0;bottom:0;z-index:21;background:#fff;border-top:1px solid var(--line);border-radius:20px 20px 0 0;padding:8px 16px 14px;box-shadow:0 -12px 32px rgba(0,35,67,.14);max-height:78%;overflow:auto}
.sheet-handle{width:42px;height:4px;border-radius:999px;background:#D6DFE1;margin:0 auto 8px}.sheet-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:10px}.sheet-head h3{font-size:var(--subtitle);line-height:1.22;color:var(--blue);font-weight:700;margin-top:2px}.sheet-head p{font-size:var(--label);line-height:1.4;color:var(--muted);margin-top:4px}.close-btn{width:36px;height:36px;border:0;border-radius:10px;background:#F2F6F6;color:var(--blue);font-size:24px;line-height:1;cursor:pointer;flex:0 0 36px;display:grid;place-items:center}.sheet-options{display:grid;grid-template-columns:1fr;gap:8px}
.sheet-option{width:100%;border:1.5px solid #B7C8CC;border-radius:14px;background:#fff;padding:11px 14px;display:grid;grid-template-columns:26px minmax(0,1fr);gap:12px;align-items:start;text-align:left;cursor:pointer;color:var(--text)}.sheet-option:hover{border-color:var(--blue);background:#FBFCFC}.sheet-option.selected{border-color:var(--green);background:var(--success-soft)}.sheet-option span:last-child{font-size:var(--body);line-height:1.45}.sheet-option .radio{margin-top:1px}
/* STAGE TRANSITIONS */
.bridge-layout{width:min(900px,100%);height:100%;display:flex;align-items:center;justify-content:center}.bridge-card{width:100%;background:#fff;border:1px solid var(--line);border-radius:16px;padding:28px 32px;text-align:center}.success-circle{width:66px;height:66px;border-radius:50%;background:var(--success-soft);color:var(--green-dark);display:grid;place-items:center;margin:0 auto 14px}.success-circle svg{width:34px;height:34px;fill:none;stroke:currentColor;stroke-width:2.2;stroke-linecap:round;stroke-linejoin:round}.bridge-card h2{font-size:var(--heading);line-height:1.18;color:var(--blue);font-weight:700}.bridge-card>p{font-size:var(--body);line-height:1.5;color:var(--text-2);max-width:680px;margin:8px auto 0}.next-stage{margin:16px auto 0;max-width:760px;background:#F4FCF9;border-left:4px solid var(--green);padding:11px 14px;text-align:left;border-radius:0 12px 12px 0;font-size:var(--body);line-height:1.45;color:var(--text)}.next-stage strong{color:var(--deep)}
/* AUDIT — single sequential page, no left/right split */
.audit-layout{width:min(1140px,100%);height:100%;min-height:0}.audit-card{height:100%;background:#fff;border:1px solid var(--line);border-radius:16px;padding:14px 18px;display:flex;flex-direction:column;min-height:0;overflow:hidden}
.audit-head{flex:0 0 auto}.audit-head h2{font-size:var(--subtitle);line-height:1.22;color:var(--blue);font-weight:700;margin-top:2px}.audit-head p{font-size:var(--body);line-height:1.45;color:var(--text-2);margin-top:4px}.evidence-label{font-size:var(--label);font-weight:700;color:var(--green-dark);margin:10px 0 5px}
.compact-thread{flex:none;min-height:0;max-height:156px;overflow:auto;background:#F8FAFA;border:1px solid var(--line);border-radius:14px;padding:9px 12px;display:flex;flex-direction:column;gap:8px}.compact-thread .chat-row{gap:8px}.compact-thread .chat-bubble{font-size:var(--body);line-height:1.42;padding:8px 12px;max-width:82%}.compact-thread .avatar{width:34px;height:34px;min-width:34px;min-height:34px;flex:0 0 34px}.compact-thread .speaker{font-size:var(--label);margin-bottom:2px}
.audit-question{margin-top:10px;flex:0 0 auto}.audit-question h3{font-size:var(--subtitle);line-height:1.22;color:var(--blue);font-weight:700}.audit-question p{font-size:var(--label);line-height:1.4;color:var(--muted);margin-top:3px}
.option-list{display:flex;flex-direction:column;gap:8px;margin-top:8px}.option-card{width:100%;min-height:52px;background:#fff;border:1.5px solid var(--line-strong);border-radius:16px;padding:9px 12px;display:grid;grid-template-columns:26px minmax(0,1fr);align-items:center;gap:12px;text-align:left;cursor:pointer;color:var(--text)}.option-card:hover{border-color:var(--blue)}.option-card.selected{border-color:var(--green);background:var(--success-soft)}
.radio{width:26px;height:26px;flex:0 0 26px;border:2px solid var(--line-strong);border-radius:50%;display:grid;place-items:center;background:#fff}.option-card.selected .radio,.sheet-option.selected .radio{border-color:var(--green)}.option-card.selected .radio:after,.sheet-option.selected .radio:after{content:"";width:10px;height:10px;border-radius:50%;background:var(--green)}
.option-main{display:block;font-size:var(--body);line-height:1.35;color:var(--deep);font-weight:700}.option-help{display:block;font-size:var(--label);line-height:1.35;color:var(--text-2);margin-top:2px}.option-copy{font-size:var(--body);line-height:1.45;color:var(--text);min-width:0}
/* CALIBRATION — one vertical sequence */
.calibration-layout{width:min(1040px,100%);height:100%;min-height:0}.calibration-card{height:100%;background:#fff;border:1px solid var(--line);border-radius:16px;padding:14px 18px;display:flex;flex-direction:column;min-height:0;overflow:hidden}.calibration-card h2{font-size:var(--subtitle);line-height:1.22;color:var(--blue);font-weight:700}.calibration-card>p{font-size:var(--body);line-height:1.45;color:var(--text-2);margin-top:4px}.key-exchange{margin-top:10px;max-height:124px}.rating-compare{margin-top:10px;display:grid;gap:8px}.rating-row{display:grid;grid-template-columns:170px minmax(0,1fr);gap:12px;align-items:start;padding:9px 12px;border:1px solid var(--line);border-radius:12px;background:#fff}.rating-row strong{font-size:var(--label);line-height:1.35;color:var(--blue);font-weight:700}.rating-row div{font-size:var(--body);line-height:1.42;color:var(--text)}.rating-tag{display:inline-flex;padding:4px 8px;border-radius:999px;background:var(--error-soft);color:var(--error);font-size:var(--label);font-weight:700;margin-right:6px}.rating-tag.high{background:var(--blue-soft);color:var(--blue)}
.calibration-question{margin-top:10px}.calibration-question h3{font-size:var(--subtitle);line-height:1.22;color:var(--blue);font-weight:700}.calibration-question p{font-size:var(--label);line-height:1.4;color:var(--muted);margin-top:3px}
/* DEVELOP — evidence and decision are separated into two screens */
.develop-layout{width:min(1040px,100%);height:100%;min-height:0}.develop-card{height:100%;background:#fff;border:1px solid var(--line);border-radius:16px;padding:16px 18px;display:flex;flex-direction:column;min-height:0;overflow:hidden}.develop-card h2{font-size:var(--subtitle);line-height:1.22;color:var(--blue);font-weight:700}.develop-card>p{font-size:var(--body);line-height:1.45;color:var(--text-2);margin-top:4px}.develop-card .compact-thread{max-height:none;flex:1;margin-top:12px}.develop-decision .option-list{margin-top:14px;gap:10px}.develop-decision .option-card{min-height:72px;padding:10px 14px}
/* SUMMARY — same family as reference activity */
.summary-screen{display:grid;grid-template-rows:minmax(0,1fr) 80px;background:var(--soft)}.summary-main{padding:26px 48px;min-height:0;display:flex;align-items:center;justify-content:center}.summary-wrap{width:min(1100px,100%)}.summary-heading h1{font-size:var(--display);line-height:1.18;color:var(--blue);font-weight:700}.summary-heading p{font-size:var(--body);line-height:1.5;color:var(--text-2);margin-top:8px;max-width:900px}.summary-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin-top:16px}.summary-card{background:#fff;border:1px solid var(--line);border-top:4px solid var(--blue);border-radius:16px;padding:18px;min-width:0}.summary-card h2{font-size:var(--subtitle);line-height:1.22;color:var(--deep);font-weight:700}.summary-list{display:flex;flex-direction:column;gap:8px;margin-top:10px}.summary-item{padding:8px 10px;border-radius:10px;background:var(--blue-soft);font-size:var(--body);line-height:1.4;color:var(--text)}.summary-item strong{color:var(--deep)}.summary-note{border-left:4px solid var(--green);background:#fff;padding:10px 14px;border-radius:0 12px 12px 0;font-size:var(--body);line-height:1.45;color:var(--text);margin-top:14px}
/* COMPLETION */
.completion-screen{display:flex;align-items:center;justify-content:center;background:#F1FAF7}.completion-card{width:760px;max-width:calc(100% - 48px);background:#fff;border:1px solid #DDECE7;border-radius:24px;padding:42px 34px;text-align:center;box-shadow:0 12px 32px rgba(0,35,67,.08)}.complete-mark{width:76px;height:76px;border-radius:50%;background:var(--success-soft);color:var(--green-dark);display:grid;place-items:center;margin:0 auto 18px}.complete-mark svg{width:38px;height:38px;fill:none;stroke:currentColor;stroke-width:2.2;stroke-linecap:round;stroke-linejoin:round}.completion-card h1{font-size:var(--display);line-height:1.18;color:var(--blue);font-weight:700}.completion-card p{font-size:var(--body);line-height:1.5;color:var(--text-2);margin:12px auto 0;max-width:620px}
/* FEEDBACK — copied to match T-EPA3 Activity 2 */
.feedback-overlay{position:absolute;inset:0;z-index:50;background:rgba(0,35,67,.33);display:flex;align-items:center;justify-content:center;padding:24px}.feedback-card{width:min(620px,calc(100% - 48px));max-height:calc(100% - 48px);overflow:hidden;background:#fff;border-radius:16px;padding:28px 32px 24px;box-shadow:var(--shadow);display:grid;gap:18px}.feedback-status{display:flex;flex-direction:column;align-items:center;gap:10px;text-align:center}.feedback-icon{width:56px;height:56px;border-radius:50%;display:grid;place-items:center}.feedback-icon svg{width:30px;height:30px;fill:none;stroke:currentColor;stroke-width:2.3;stroke-linecap:round;stroke-linejoin:round}.feedback-card.correct .feedback-icon{background:var(--success-soft);color:var(--green-dark)}.feedback-card.incorrect .feedback-icon{background:var(--error-soft);color:var(--error)}.feedback-status h2{font-size:var(--heading);line-height:1.18;font-weight:700}.feedback-card.correct .feedback-status h2{color:var(--green-dark)}.feedback-card.incorrect .feedback-status h2{color:var(--error)}.feedback-body{overflow:auto;min-height:0}.feedback-body p{font-size:var(--body);line-height:1.5;color:var(--text);text-align:left}.feedback-actions{display:flex;justify-content:center}.feedback-actions .btn{min-width:188px}
@media (prefers-reduced-motion:reduce){.chat-row.message-enter{opacity:1;transform:none;animation:none}}
@media(max-width:820px){
  .app-shell{padding:0;min-height:680px}.activity-frame{height:680px;border-left:0;border-right:0;border-radius:0}
  .start-screen{grid-template-columns:minmax(0,56%) minmax(0,44%)}.start-copy{padding:32px}.start-copy h1{font-size:28px}.start-art{padding:24px 16px 24px 0}
  .instructions-main{padding:28px 24px 16px}.instruction-grid{gap:12px}.instruction-card{padding:16px;min-height:200px}.instruction-card h2{font-size:18px}.instructions-heading h1{font-size:28px}
  .task-title h1{font-size:22px}.progress-track{width:160px}.content{padding:10px 12px}.action-center{display:none}
  .compact-thread{max-height:132px}.rating-row{grid-template-columns:145px minmax(0,1fr)}
  .summary-main{padding:22px 24px}.summary-heading h1{font-size:28px}.summary-grid{gap:12px}.summary-card{padding:14px}.summary-card h2{font-size:18px}
  .completion-card{padding:34px 24px}.completion-card h1{font-size:28px}.feedback-status h2{font-size:22px}
}
