/* أكاديمية الإمام — لوحة قيادة واحدة لكل دور. هذا الملف مالك تصميم لوحة الدور فقط.
   لا تُخفي العناصر في CSS باعتبار ذلك تحققًا من الصلاحية: الصلاحيات من الخادم. */
#pg-home > #roleHomeHub,
#pg-home.v9-home-ready > #roleHomeHub{display:block!important;width:100%;direction:rtl;box-sizing:border-box;margin:0 0 18px}
#pg-home.v92-home-ready{max-width:1380px!important;width:100%;box-sizing:border-box}
#pg-home.v92-home-ready:not(.on){display:none!important}
#pg-home[data-workspace-role] > #supervisorShortcut{display:none!important}
/* لا يجمع المشرف والمالك واجهة الحلقة القديمة مع لوحة الإدارة. تبقى لوحة الحلقة عند اختيار مساحة التحفيظ. */
#pg-home[data-workspace-role="supervisor"] #v9Home,
#pg-home[data-workspace-role="owner"] #v9Home{display:none!important}
#pg-home[data-workspace-role="teacher"] #v9Home{display:grid}
#pg-home[data-workspace-role="owner"] #roleHomeHub{--role-accent:#c3a168;--role-tint:#f8f2e6}
#pg-home[data-workspace-role="supervisor"] #roleHomeHub{--role-accent:#81c7b7;--role-tint:#e8f7f3}
#pg-home[data-workspace-role="teacher"] #roleHomeHub{--role-accent:#82b9cc;--role-tint:#e6f3f8}
.role-home-hub{background:var(--ui-surface);border:1px solid var(--ui-line);border-radius:24px;box-shadow:0 12px 35px rgba(5,47,35,.06);overflow:hidden;color:var(--ui-ink)}
.role-home-head { background:radial-gradient(circle at 9% 25%,rgba(204,178,115,.18),transparent 32%),linear-gradient(125deg,#0d433b,#102d36);color:#fff;padding:20px 23px 10px;display:flex;align-items:center;justify-content:space-between;gap:14px; }
.role-home-head::before{display:none}
.role-hero-copy{min-width:0;flex:1}
.role-hero-eyebrow{display:inline-block;font-size:12px;font-weight:700;color:#f1d5a0;margin-bottom:3px}
.role-home-head h2{margin:0 0 4px;color:#fff;font-size:clamp(22px,2vw,27px);line-height:1.35;font-weight:850}
.role-home-head small{display:block;font-size:13px;line-height:1.6;color:#e5f2ec}
.role-home-tools{display:flex;gap:7px;flex-wrap:wrap;align-items:center;justify-content:flex-end}
.role-home-tag,.role-workspace-toggle,.role-help-toggle{min-height:40px;padding:8px 11px;border:1px solid rgba(255,255,255,.3);background:rgba(255,255,255,.11);color:#fff;border-radius:11px;font-size:13px;font-weight:700;display:inline-flex;align-items:center;justify-content:center}
.role-workspace-toggle:hover,.role-help-toggle:hover{background:rgba(255,255,255,.24)}
.role-hero-actions{padding:5px 23px 19px;background:linear-gradient(125deg,#0d433b,#102d36);display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.role-hero-next,.role-hero-board{min-height:47px;padding:10px 16px;border-radius:12px;font-size:14px;font-weight:800;transition:transform .15s,background .15s;white-space:normal}
.role-hero-next{background:#f5d48d;border:1px solid #f5d48d;color:#243629;box-shadow:none}
.role-hero-next:hover{background:#ffe4ab;transform:translateY(-1px)}
.role-hero-board{color:#fff;border:1px solid rgba(255,255,255,.32);background:rgba(255,255,255,.12);box-shadow:none}
.role-hero-board:hover{background:rgba(255,255,255,.24)}
.role-hero-caption{color:#d5e5de;font-size:12px}
.role-actions-heading{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:18px 22px 12px}
.role-actions-heading h3{font-size:17px;line-height:1.4;margin:0;color:var(--ui-ink)}
.role-actions-heading span{font-size:13px;color:var(--ui-muted)}
.role-home-actions { display:grid; grid-template-columns:repeat(3,minmax(0,1fr));gap:9px;padding:0 22px 22px; }
.role-home-action{min-width:0;min-height:74px;display:flex;align-items:center;gap:11px;text-align:start;padding:12px;border-radius:14px;border:1px solid var(--ui-line);background:var(--ui-surface);color:var(--ui-ink);transition:border-color .15s,background .15s,transform .15s}
.role-home-action:hover,.role-home-action:focus-visible{border-color:var(--ui-primary);background:var(--ui-soft);transform:translateY(-1px)}
.role-home-action .role-icon{width:42px;height:42px;flex:none;border-radius:12px;display:grid;place-items:center;background:var(--role-tint);font-size:21px}
.role-home-action b{font-size:14px;line-height:1.4;display:block;font-weight:800;overflow-wrap:anywhere}
.role-home-action small{display:block;color:var(--ui-muted);font-size:12px;line-height:1.5;margin-top:3px;overflow-wrap:anywhere}
.role-home-action.role-action-featured{grid-column:span 2;min-height:74px;background:var(--ui-soft);border-color:color-mix(in srgb,var(--ui-primary) 30%,var(--ui-line))}
.role-home-action.role-action-featured .role-icon{width:42px;height:42px;font-size:21px}
.role-home-action.role-action-featured b{font-size:15px;color:var(--ui-primary)}
.role-home-action.role-action-featured small{font-size:12px;color:var(--ui-muted)}
.role-home-footnote{color:var(--ui-muted);margin:0 22px 18px;font-size:12px;line-height:1.6}
.role-report-modal{z-index:1500}
#update-banner.show{display:flex!important}
#update-banner.updating{opacity:.85}
#update-banner{direction:rtl;z-index:20000}
#update-banner button{min-height:40px}
/* مساحات الإدارة لا تعرض تكرارات الإجراءات التي أنشأتها الواجهة التعليمية الأقدم. */
#pg-home[data-workspace-role] #v9Home .v92-actions{display:none!important}
#pg-home.v92-home-ready #roleHomeHub{width:100%;margin-bottom:15px}
@media(min-width:1050px){#pg-home.v92-home-ready.on{display:block!important;max-width:1300px}}
@media(max-width:760px){.role-home-actions{grid-template-columns:repeat(2,minmax(0,1fr));padding:0 13px 16px}.role-actions-heading{padding:16px 15px 10px}.role-home-head{padding:17px 16px 9px}.role-hero-actions{padding:6px 16px 14px}.role-home-footnote{margin:0 16px 14px}}
@media(max-width:480px){
 .role-home-hub{border-radius:18px}.role-home-head{align-items:flex-start;flex-direction:column;gap:8px}.role-home-head h2{font-size:23px}.role-home-head small{font-size:12px}
 .role-home-tools{justify-content:flex-start}.role-hero-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
 .role-hero-next,.role-hero-board{width:100%;min-height:47px;font-size:13px;padding:8px}
 .role-hero-caption{grid-column:1/-1;text-align:center}.role-home-action{flex-direction:row;align-items:center;min-height:74px;padding:10px;gap:7px}
 .role-home-action .role-icon{width:35px;height:35px;font-size:18px}.role-home-action b{font-size:12px}.role-home-action small{font-size:12px;line-height:1.4}
 .role-home-action.role-action-featured{grid-column:1/-1}.role-actions-heading{align-items:baseline;flex-wrap:wrap}
}
@media(max-width:325px){.role-home-actions{grid-template-columns:1fr}.role-home-action.role-action-featured{grid-column:1}}
:root[data-theme="dark"] .role-home-action.role-action-featured{background:var(--ui-soft)}
:root[data-theme="dark"] .role-home-action.role-action-featured b{color:var(--ui-ink)}
@media(prefers-reduced-motion:reduce){.role-home-action,.role-hero-next,.role-hero-board{transition:none;transform:none}}

/* beta15 review — admin shortcut is strictly singular even if legacy stylesheet loads later. */
#pg-home[data-workspace-role].v9-home-ready > #supervisorShortcut.supervision-home-entry,
#pg-home[data-workspace-role] > #supervisorShortcut[hidden].supervision-home-entry{display:none!important}
