/* ✨ التصميم العصري (المرحلة 1): الخط، الشريط العلوي، شريط التنقل السفلي، البطاقات.
   هيكل فقط — الألوان كلها من متغيرات «مظهر التطبيق» (theme-picker.js)، فيعمل مع أي ثيم أو ألوان مخصّصة.
   يُحمَّل آخر ملفات التنسيق ليغلب ما قبله. لا يمس الطباعة. */
/* الخط مستضاف مع الموقع (لا طلب خارجي يحجب العرض، ويعمل بلا اتصال) — IBM Plex Sans Arabic، عربي ولاتيني فقط */
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:400;font-display:swap;src:url(fonts/plex-arabic-400-arabic.woff2) format('woff2');unicode-range:U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC7, U+10EC9-10EEE, U+10EF0-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1}
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:400;font-display:swap;src:url(fonts/plex-arabic-400-latin.woff2) format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD}
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:500;font-display:swap;src:url(fonts/plex-arabic-500-arabic.woff2) format('woff2');unicode-range:U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC7, U+10EC9-10EEE, U+10EF0-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1}
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:500;font-display:swap;src:url(fonts/plex-arabic-500-latin.woff2) format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD}
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:600;font-display:swap;src:url(fonts/plex-arabic-600-arabic.woff2) format('woff2');unicode-range:U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC7, U+10EC9-10EEE, U+10EF0-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1}
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:600;font-display:swap;src:url(fonts/plex-arabic-600-latin.woff2) format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD}
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:700;font-display:swap;src:url(fonts/plex-arabic-700-arabic.woff2) format('woff2');unicode-range:U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC7, U+10EC9-10EEE, U+10EF0-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1}
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:700;font-display:swap;src:url(fonts/plex-arabic-700-latin.woff2) format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD}
@media screen{
/* ألوان «عصري» هي الأساس نفسه (لا ينتظر الشكلُ الجديد أيَّ سكربت). الثيمات الأخرى تُطبَّق فوقها من theme-picker.js */
:root{--paper:#F5F7F9;--paper-2:#FFFFFF;--ink:#0F1A24;--ink-soft:#6B7785;--ui-muted:#6B7785;--rule:#E3E8ED;--ui-bg:#F5F7F9;--ui-surface:#FFFFFF;--ui-surface-2:#F5F7F9;--ui-border:#E8ECF0;--ui-border-strong:#D5DCE3;--ui-accent:#0F9D74;--ui-accent-soft:#E7F6F0;--app-nav-bg:#FFFFFF;--app-nav-text:#0F1A24;--app-nav-muted:#6B7785;--app-nav-active:#E7F6F0;--app-nav-active-text:#0B7A5A;--card:#FFFFFF}
:root{--m-r:16px;--m-r-sm:12px;--m-sh:0 1px 2px rgba(16,24,40,.04),0 4px 14px rgba(16,24,40,.06);--m-font:'IBM Plex Sans Arabic','Readex Pro','Tajawal','Segoe UI',system-ui,sans-serif}
body{font-family:var(--m-font)!important;background:var(--paper)!important;-webkit-font-smoothing:antialiased}
button,input,select,textarea{font-family:inherit}

/* ── الشريط العلوي: فاتح ونظيف، بخط فاصل رفيع بدل الشريط الملوّن ── */
.masthead{border-bottom:1px solid var(--ui-border)!important;box-shadow:none!important}
.masthead,.masthead .brand,.masthead .brand-txt,.masthead .meta{color:var(--app-nav-text)!important}
.masthead .brand{font-weight:700;letter-spacing:0}
.masthead .brand .mark{width:34px!important;height:34px!important;border-radius:10px!important;background:var(--ui-accent)!important;box-shadow:none!important;border:0!important;position:relative;overflow:hidden}
.masthead .brand .mark::before,.masthead .brand .mark::after{content:''!important;position:absolute!important;inset:8px!important;background:none!important;border:0!important;width:auto!important;height:auto!important;transform:none!important;
  -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4' y='4' width='7' height='7' rx='1.5'/%3E%3Crect x='13' y='4' width='7' height='7' rx='1.5'/%3E%3Crect x='4' y='13' width='7' height='7' rx='1.5'/%3E%3Crect x='13' y='13' width='7' height='7' rx='1.5'/%3E%3C/svg%3E") center/contain no-repeat;
  mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4' y='4' width='7' height='7' rx='1.5'/%3E%3Crect x='13' y='4' width='7' height='7' rx='1.5'/%3E%3Crect x='4' y='13' width='7' height='7' rx='1.5'/%3E%3Crect x='13' y='13' width='7' height='7' rx='1.5'/%3E%3C/svg%3E") center/contain no-repeat;background-color:#fff!important}
.masthead .brand .mark::before{display:none!important}
/* ✋ الرصد: زر أساسي واضح */
#portal-link-btn{background:var(--ui-accent)!important;color:#fff!important;border:0!important;border-radius:999px!important;padding:.45rem .9rem!important;font-weight:700!important}
#portal-link-btn .portal-w{display:inline!important}
.masthead .btn.ghost:not(#portal-link-btn),.masthead .onl-chip{background:var(--ui-surface-2)!important;border-color:transparent!important;color:var(--ink-soft)!important}

/* ── شريط التنقل السفلي (الجوال) ── */
#simp-bottomnav{background:var(--ui-surface)!important;border-top:1px solid var(--ui-border)!important;box-shadow:0 -2px 12px rgba(16,24,40,.04)!important}
#simp-bottomnav button{background:transparent!important;color:var(--ui-muted)!important;border-radius:12px!important}
#simp-bottomnav button b{font-weight:600}
#simp-bottomnav button.on{background:transparent!important;color:var(--app-nav-active-text)!important}
#simp-bottomnav button.on .simp-bic{background:var(--app-nav-active);border-radius:999px;padding:3px 16px}
#simp-strip{background:transparent!important;border:0!important;padding:0!important}
.simp-chip{background:var(--ui-surface)!important;border-color:var(--ui-border)!important;box-shadow:none}
.simp-chip.on{background:var(--app-nav-active)!important;color:var(--app-nav-active-text)!important;border-color:transparent!important}

/* ── البطاقات: بيضاء بظل ناعم وزوايا موحّدة بدل الحدود ── */
.sheet,.card,.td-card,.stat-card,.ct-card{background:var(--ui-surface)!important;border-color:transparent!important;border-radius:var(--m-r)!important;box-shadow:var(--m-sh)!important}
.sheet .sheet,.card .card,.sheet .card,.card .ct-card,.sheet .ct-card{box-shadow:none!important;border:1px solid var(--ui-border)!important}
.inp,input.inp,select.inp,textarea.inp{border-radius:var(--m-r-sm)!important;border-color:var(--ui-border)!important}

/* ═════ المرحلة 2: الأزرار والبطاقات الداخلية ═════ */
/* الأزرار: الأساسي بلون التمييز، والثانوي أبيض بحد رفيع */
.btn:not(.ghost):not(.tick):not(.pen):not(.danger):not(.bad){background:var(--ui-accent)!important;color:#fff!important}
.btn{border-radius:var(--m-r-sm)!important;box-shadow:none!important;font-weight:600}
.btn:hover{transform:none!important;filter:brightness(1.05)}
.btn.ghost{background:var(--ui-surface)!important;color:var(--ink)!important;box-shadow:inset 0 0 0 1px var(--ui-border)!important}
.btn.ghost:hover{background:var(--ui-surface-2)!important}
.btn.sm{border-radius:10px!important}

/* «اليوم»: بطاقة الحصة بلون التمييز (ثيم عصري) أو لون الشريط (الثيمات الأخرى) */
.td-hero{background:var(--m-hero,var(--ui-accent))!important;background-image:none!important;color:var(--m-hero-ink,#FFFFFF)!important;border-radius:var(--m-r)!important;box-shadow:0 6px 18px rgba(16,24,40,.12)!important;box-shadow:0 6px 18px color-mix(in srgb,var(--ui-accent) 22%,transparent)!important}
.td-hero small{opacity:.88}
.td-ring{background:conic-gradient(#fff calc(var(--p)*1%),rgba(255,255,255,.22) 0)!important}
.td-ring i{background:var(--m-hero,var(--ui-accent))!important;color:var(--m-hero-ink,#FFFFFF)!important}
.td-hero-go{background:#fff!important;color:var(--ui-accent)!important;border-radius:12px!important;box-shadow:0 1px 3px rgba(0,0,0,.08)}
.td-kpi{background:var(--ui-surface)!important;border:0!important;box-shadow:var(--m-sh)!important}
.td-kpi.on{box-shadow:0 0 0 2px var(--ui-accent),var(--m-sh)!important}
.td-per{border:0!important;background:var(--ui-surface-2)!important;font-weight:600}
.td-per.miss{background:#FDF4E1!important;color:#8A5A00!important}
.td-task{background:var(--ui-surface-2)!important;border-radius:var(--m-r-sm)!important}
.td-day{border-radius:var(--m-r-sm)!important;border-color:var(--ui-border)!important}
.td-day.today{border-color:var(--ui-accent)!important;box-shadow:0 0 0 1px var(--ui-accent)}
details.td-more{background:var(--ui-surface)!important;border:0!important;border-radius:var(--m-r)!important;box-shadow:var(--m-sh)!important}

/* ✋ الرصد السريع: صفوف بيضاء وأزرار تتلوّن عند الاختيار فقط */
.qr-row{background:var(--ui-surface)!important;border:0!important;box-shadow:var(--m-sh);border-radius:var(--m-r-sm)!important}
.qr-row.done{box-shadow:inset -3px 0 0 var(--ui-accent),var(--m-sh)}
.qr-row .c:not(.on){background:var(--ui-surface)!important;border:1.5px solid var(--ui-border)!important}
.qr-row .c.g.on{background:var(--ui-accent-soft)!important;border-color:var(--ui-accent)!important}
.qr-row .c.y.on{background:#FDF4E1!important;border-color:#E8A317!important}
.qr-row .c.r.on{background:#FDECEC!important;border-color:#E5484D!important}
.qr-mode{background:var(--ui-surface-2)!important;border:0!important}
.qr-mode button.on{background:var(--ui-surface)!important;color:var(--ink)!important}
.qr-cnt>div{background:var(--ui-surface)!important;box-shadow:var(--m-sh)}
.qr-s,.qr-ic{background:var(--ui-surface)!important;border-color:var(--ui-border)!important}
.qr-all{background:var(--ui-accent)!important;border-radius:var(--m-r)!important}
.qr-lesson{background:var(--ui-accent-soft)!important;border:0!important;border-radius:var(--m-r)!important}
.qr-lesson .x{background:var(--ui-accent)!important}

/* شاشات البوابة المنقولة (الاختبارات، الجدول، الرسائل): ألوانها من الثيم نفسه */
.tpx.tpx{--surface:var(--ui-surface);--surface-2:var(--ui-surface-2);--surface-3:var(--ui-surface-2);--paper:var(--ui-bg);--rule:var(--ui-border);--rule-strong:var(--ui-border-strong);
  --accent:var(--ui-accent);--accent-soft:var(--ui-accent-soft);--accent-ink:var(--app-nav-active-text);--ink-soft:var(--ui-muted);--font:var(--m-font);--shadow:var(--m-sh)}

/* أدوات الفصل: أزرار الأقسام */
.ct-seg{border-radius:var(--m-r-sm)!important}
.ct-seg button.on{background:var(--ui-accent)!important;color:#fff!important}
#portal-link-btn{box-shadow:0 2px 8px rgba(16,24,40,.14)!important;box-shadow:0 2px 8px color-mix(in srgb,var(--ui-accent) 30%,transparent)!important}
#ct-nav .btn{border-radius:999px!important}

/* ═════ المرحلة 3: الأيقونات الخطية (js/45-icons.js) ═════ */
.ico{width:1.15em;height:1.15em;stroke:currentColor;fill:none;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;vertical-align:-.2em;flex:none;display:inline-block}
#simp-bottomnav .simp-bic .ico,#fm-bot i .ico{width:24px;height:24px;vertical-align:middle}
#simp-bottomnav .simp-bic{display:inline-flex;align-items:center;justify-content:center;min-height:30px}
.app-nav-icon .ico{width:20px;height:20px}
.qr-row .c{filter:none!important;opacity:1!important;color:#A8B1BB;display:inline-grid;place-items:center}
.qr-row .c .ico{width:22px;height:22px;stroke-width:2}
.qr-row .c.g.on{color:var(--ui-accent)!important}.qr-row .c.y.on{color:#B7791F!important}.qr-row .c.r.on{color:#E5484D!important}
.qr-ic .ico{width:20px;height:20px;color:var(--ui-muted)}
.qr-s .ico{color:var(--ui-muted)}
.qr-mode button .ico,#ct-nav .btn .ico,.simp-chip .ico,.ct-seg button .ico{margin-inline-end:.15em}
#portal-link-btn .ico{width:18px;height:18px}
.td-kpi span .ico{color:var(--ui-accent)}
.panel > .sheet-head h2 .ico,.td-head h2 .ico,#ct-title .ico{color:var(--ui-accent);width:1em;height:1em;vertical-align:-.12em}
.td-hero-t > b .ico{opacity:.9}
.td-task .td-ic .ico{color:#B7791F;width:20px;height:20px}
.td-link .ico,.td-abs > b .ico{color:var(--ui-accent)}

/* 🎯 وضع الحصة: الشريط العلوي بنفس الشكل الجديد (فاتح، بلون الثيم) */
body.fm #fm-top{background:var(--app-nav-bg)!important;color:var(--app-nav-text)!important;border-bottom:1px solid var(--ui-border);gap:.55rem!important;padding:.6rem .9rem!important;padding-top:calc(.6rem + env(safe-area-inset-top,0px))!important}
#fm-top .fm-ic{flex:none;width:38px;height:38px;border-radius:11px;background:var(--ui-accent);color:#fff;display:grid;place-items:center}
#fm-top .fm-ic .ico{width:22px;height:22px}
#fm-top .fm-t b{display:flex!important;align-items:center;gap:.35rem;font-size:1.02rem!important}
#fm-top .fm-t small{color:var(--ui-muted);opacity:1!important;font-size:.78rem!important}
#fm-top .fm-chev .ico{width:16px;height:16px;color:var(--ui-muted);vertical-align:middle}
#fm-top .fm-dot{width:8px;height:8px;border-radius:50%;background:#22C55E;display:inline-block;flex:none;box-shadow:0 0 0 3px rgba(34,197,94,.18)}
#fm-top .fm-tm{display:inline-flex;align-items:center;gap:.25rem;background:var(--ui-accent-soft)!important;color:var(--app-nav-active-text)!important;border-radius:10px!important;padding:.35rem .6rem!important;font-weight:700!important}
#fm-top .fm-tm .ico{width:15px;height:15px}
#fm-top .fm-x{display:inline-flex;align-items:center;gap:.25rem;background:var(--ui-surface-2)!important;color:var(--ui-muted)!important;border:0!important;border-radius:10px!important;padding:.45rem .65rem!important;font-weight:600!important}
#fm-top .fm-x .ico{width:16px;height:16px}
#fm-bot{border-top-color:var(--ui-border)!important}
#fm-bot button.on{background:var(--ui-accent-soft)!important;color:var(--app-nav-active-text)!important}
#fm-top .fm-chev{flex:none;display:inline-flex}
#fm-top .fm-t b{overflow:visible!important}#fm-top .fm-tt{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:inline-flex;align-items:center;gap:.35rem}
.tpx .rd-ic .ico{width:20px;height:20px;color:var(--ui-muted)}
.tpx .ex-tools button .ico{color:var(--ui-accent)}
.stat-icon .ico,.report-hub-icon .ico{width:1.3em;height:1.3em;color:var(--ui-accent)}
summary .ico,h3 .ico,h4 .ico,b .ico{color:var(--ui-accent)}
.btn:not(.ghost) .ico{color:inherit}
.askf-ic .ico{width:26px;height:26px;color:#fff}
}







/* ═══ 🗓️ وضع الحصة: لوحة «جدول اليوم» من أسفل الشاشة (بدل قائمة الاختيار) ═══ */
#fm-top button.fm-t{background:none;border:0;padding:0;margin:0;font:inherit;color:inherit;text-align:right;display:block;-webkit-tap-highlight-color:transparent}
#fm-sheet{position:fixed;inset:0;z-index:2147483000;font-family:var(--m-font)}
#fm-sheet .fms-dim{position:absolute;inset:0;background:rgba(15,26,36,.38);opacity:0;transition:opacity .2s}
#fm-sheet .fms-box{position:absolute;left:0;right:0;bottom:0;max-height:84vh;overflow:auto;overscroll-behavior:contain;background:var(--ui-surface,#fff);color:var(--ink,#0F1A24);border-radius:22px 22px 0 0;padding:8px 16px calc(18px + env(safe-area-inset-bottom,0px));box-shadow:0 -10px 40px rgba(0,0,0,.18);transform:translateY(100%);transition:transform .24s cubic-bezier(.2,.8,.2,1)}
#fm-sheet.on .fms-dim{opacity:1}#fm-sheet.on .fms-box{transform:none}
@media (min-width:700px){#fm-sheet .fms-box{max-width:520px;margin:0 auto}}
#fm-sheet .fms-grab{width:40px;height:5px;border-radius:3px;background:var(--ui-border-strong,#D5DCE3);margin:2px auto 12px}
#fm-sheet .fms-h{display:flex;align-items:baseline;justify-content:space-between;gap:.5rem;margin-bottom:12px}
#fm-sheet .fms-h b{font-size:1.12rem}#fm-sheet .fms-h small{color:var(--ui-muted);font-size:.82rem}
#fm-sheet .fms-l{display:flex;align-items:center;gap:12px;width:100%;padding:11px 12px;border:1.5px solid var(--ui-border,#E8ECF0);border-radius:14px;margin:0 0 8px;background:var(--ui-surface,#fff);color:inherit;font:inherit;text-align:right;cursor:pointer}
#fm-sheet .fms-n{width:38px;height:38px;border-radius:12px;background:var(--ui-surface-2,#F1F4F7);display:grid;place-items:center;font-weight:700;font-size:1rem;flex:none}
#fm-sheet .fms-m{flex:1;min-width:0}#fm-sheet .fms-m b{display:block;font-size:1rem}#fm-sheet .fms-m small{color:var(--ui-muted);font-size:.8rem}
#fm-sheet .fms-p{font-size:.75rem;font-weight:700;border-radius:999px;padding:4px 10px;white-space:nowrap;background:var(--ui-surface-2,#F1F4F7);color:var(--ink-soft,#3A4754)}
#fm-sheet .fms-l.done{opacity:.62}
#fm-sheet .fms-l.now{border-color:var(--ui-accent);background:var(--ui-accent-soft)}#fm-sheet .fms-l.now .fms-n,#fm-sheet .fms-l.now .fms-p{background:var(--ui-accent);color:#fff}
#fm-sheet .fms-l.next .fms-p{background:#FFF4DE;color:#A15C00}
#fm-sheet .fms-l.on{box-shadow:0 0 0 3px var(--ui-accent-soft);border-color:var(--ui-accent);opacity:1}
#fm-sheet .fms-sub{font-size:.82rem;color:var(--ui-muted);font-weight:600;margin:14px 2px 8px}
#fm-sheet .fms-chips{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
#fm-sheet .fms-chips button{border:1.5px solid var(--ui-border,#E8ECF0);border-radius:12px;padding:11px 4px;background:var(--ui-surface,#fff);color:inherit;font:inherit;font-weight:600;font-size:.95rem;cursor:pointer}
#fm-sheet .fms-chips button.on{border-color:var(--ui-accent);background:var(--ui-accent-soft);color:var(--app-nav-active-text,#0B7A5A)}
#fm-sheet .fms-empty{background:var(--ui-surface-2,#F5F7F9);border-radius:14px;padding:14px;display:flex;gap:12px;align-items:center}
#fm-sheet .fms-empty .ico{width:26px;height:26px;color:var(--ui-muted);flex:none}#fm-sheet .fms-empty b{display:block;font-size:.95rem}#fm-sheet .fms-empty small{color:var(--ui-muted);font-size:.8rem}
@media (prefers-reduced-motion:reduce){#fm-sheet .fms-box,#fm-sheet .fms-dim{transition:none}}

/* ═══ 🎤 البحث بالصوت داخل خانات البحث عن طالب (js/47-voice-search.js) ═══ */
.vs-wrap{position:relative;min-width:0;vertical-align:middle}
.vs-wrap>input{width:100%;padding-left:44px!important}
.vs-wrap>input::-webkit-search-cancel-button{display:none}
.vs-mic{position:absolute;left:6px;top:50%;transform:translateY(-50%);width:34px;height:34px;border-radius:10px;border:0;margin:0;padding:0;background:transparent;color:var(--ui-muted,#6B7785);display:grid;place-items:center;cursor:pointer;z-index:2;-webkit-tap-highlight-color:transparent}
.vs-mic:hover{background:var(--ui-surface-2,#F1F4F7);color:var(--ui-accent)}
.vs-mic .ico{width:19px;height:19px}
.vs-mic.on{background:#E5484D;color:#fff;animation:vsPulse 1.2s ease-out infinite}
@keyframes vsPulse{0%{box-shadow:0 0 0 0 rgba(229,72,77,.45)}70%{box-shadow:0 0 0 9px rgba(229,72,77,0)}100%{box-shadow:0 0 0 0 rgba(229,72,77,0)}}
@media (prefers-reduced-motion:reduce){.vs-mic.on{animation:none}}
@media print{.vs-mic{display:none!important}}

/* 🖥️ الشريط العلوي على الكمبيوتر: بلا اسم مكرر (في القائمة الجانبية)، وبحدود الصفحة نفسها (1320 مثل المحتوى)،
   الفترة يمينًا، و«متصل الآن» + «الرصد» يسارًا بارتفاع واحد. الجوال كما هو */
@media (min-width:701px){
  .masthead{background:var(--ui-surface,#fff)!important;padding-inline:0!important}
  .masthead-in{max-width:none!important;width:auto!important;min-height:60px;padding-block:.55rem!important;padding-inline:20px!important;margin-inline:max(16px,calc((100% - 1320px) / 2))!important;gap:.6rem!important;flex-wrap:nowrap!important}
  .masthead .brand{display:none!important}
  .masthead #vsp-btn{order:1;display:inline-flex;align-items:center;gap:.4rem;height:40px;padding:0 .9rem!important;border-radius:12px!important;font-weight:700!important;font-size:.9rem!important;background:var(--ui-surface-2)!important;color:var(--ink)!important;border:1px solid var(--ui-border)!important}
  .masthead #vsp-btn .ico{color:var(--ui-accent)}
  .masthead .onl-chip{order:2;margin-inline-start:auto!important;height:40px;padding:0 .9rem!important;border-radius:12px!important;font-size:.88rem!important;gap:.45rem!important;border:1px solid var(--ui-border)!important;background:var(--ui-surface)!important;color:var(--ink)!important}
  .masthead .onl-chip{white-space:nowrap}
  .masthead #portal-link-btn{order:3;margin-inline-start:0!important;height:40px;padding:0 1.1rem!important;border-radius:12px!important;font-size:.95rem!important;box-shadow:none!important}
  .masthead .onl-chip ~ #portal-link-btn, .masthead #portal-link-btn{margin-inline-start:.5rem}
  .masthead:not(:has(.onl-chip)) #portal-link-btn{margin-inline-start:auto!important}
}
/* 🏷️ رقم إصدار اللوحة وحالته (القائمة الجانبية و«المزيد») */
.app-ver{display:flex;flex-direction:column;align-items:flex-start;gap:1px;margin-top:6px;padding:4px 0;border:0;background:none;font:inherit;font-size:.7rem;color:var(--ink-soft);cursor:pointer;text-align:start}
.app-ver .av-n{font-weight:700}.app-ver bdi{direction:ltr;unicode-bidi:isolate}
.app-ver b{font-weight:700}.app-ver .av-ok{color:var(--ui-accent)}.app-ver .av-up{color:#B45309}
.simp-sh-ver{align-items:center;width:100%;margin:10px 0 0;padding:10px 0;border-top:1px solid var(--ui-border);font-size:.78rem}
.app-sidebar-head{flex-wrap:wrap}
.app-sidebar-head .app-ver{flex:1 0 100%;flex-direction:row;flex-wrap:wrap;align-items:center;gap:2px 8px;margin-top:4px}

/* v1.0.8: تجربة «لازم آخر نسخة» — تحديث بلا تغيير في الشكل */
