/* ═══════════════════════════════════════════════════════
   Al-Hadath Organizers — منصة المنظم (الدخول + اللوحة)
   ملء الشاشة. ألوان الموقع الفعلية: #0A2A4A للعناوين، #06B6D4 للأزرار.
   ═══════════════════════════════════════════════════════ */
.aho-portal {
  --navy: #0A2A4A; --navy-2: #0E3A5C; --navy-3: #071D33;
  --teal: #06B6D4; --teal-2: #009BA6; --teal-soft: #67E8F9;
  --bg: #F3F5F9; --surface: #fff; --border: #E7EAF0; --border-2: #EEF1F5;
  --text: #16233A; --muted: #6B7686; --faint: #9AA5B4;
  --ok: #0FA968; --ok-bg: #E5F7EE; --err: #E1493F; --err-bg: #FCEAE8;
  --warn: #D98A0B; --warn-bg: #FFF4DE; --info: #3B7EE0; --info-bg: #E9F0FC;
  --r-sm: 10px; --r-md: 14px; --r-lg: 20px; --r-xl: 26px;
  --shadow-sm: 0 1px 3px rgba(16,35,58,.06); --shadow-md: 0 8px 24px rgba(16,35,58,.08); --shadow-lg: 0 24px 56px rgba(10,42,74,.22);
  --ease: cubic-bezier(.4,0,.2,1);
  font-family: 'Tajawal', sans-serif; color: var(--text); background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
.aho-portal.is-ltr { font-family: 'Inter', 'Tajawal', sans-serif; }
.aho-portal *, .aho-portal *::before, .aho-portal *::after { box-sizing: border-box; }
.aho-portal button, .aho-portal input, .aho-portal select { font-family: inherit; }
.aho-portal a { text-decoration: none; }
.aho-portal h1, .aho-portal h2, .aho-portal h3, .aho-portal h4 { margin: 0; color: var(--navy); font-weight: 800; line-height: 1.35; font-family: inherit; }
/* :where() = بلا وزن تخصيص، حتى لا يطغى تصفير الهوامش على هوامش المكوّنات (.aho-auth-sub مثلاً) */
:where(.aho-portal) p { margin: 0; }

/* شريط الموقع العائم وشاشة البداية يغطّيان التطبيق — المنصة لها رأسها الخاص */
body:has(.aho-portal) #futuristicTopbar,
body:has(.aho-portal) #alhadathSplashScreen { display: none !important; }

/* ── أزرار ومكوّنات عامة ── */
.aho-btn { display: inline-flex; align-items: center; justify-content: center; gap: .45rem; padding: .7rem 1.2rem; border-radius: 999px;
  border: 1.5px solid var(--border); background: var(--surface); color: var(--text); font-weight: 700; font-size: .88rem; cursor: pointer;
  transition: transform .15s var(--ease), box-shadow .15s var(--ease), background .15s var(--ease), border-color .15s var(--ease); white-space: nowrap; line-height: 1.2; }
.aho-btn:hover { transform: translateY(-1px); border-color: #d5dae3; }
.aho-btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.aho-btn:focus-visible, .aho-chip:focus-visible, .aho-stat:focus-visible { outline: 3px solid rgba(6,182,212,.35); outline-offset: 2px; }
.aho-btn-primary { background: var(--teal); border-color: var(--teal); color: #fff; box-shadow: 0 8px 20px rgba(6,182,212,.28); }
.aho-btn-primary:hover { background: #0891B2; border-color: #0891B2; color: #fff; }
.aho-btn-success { background: var(--ok); border-color: var(--ok); color: #fff; box-shadow: 0 8px 18px rgba(15,169,104,.24); }
.aho-btn-success:hover { background: #0c9159; color: #fff; }
.aho-btn-danger { background: var(--err); border-color: var(--err); color: #fff; }
.aho-btn-ghost-danger { background: transparent; border-color: #f3c6c2; color: #b3261e; }
.aho-btn-ghost-danger:hover { background: var(--err-bg); }
.aho-btn-wa { background: #25D366; border-color: #25D366; color: #fff; }
.aho-btn-wa:hover { background: #1ebe5b; color: #fff; }
.aho-btn-block { width: 100%; }
.aho-link { color: var(--teal-2); font-weight: 700; font-size: .86rem; }
.aho-link:hover { color: var(--navy); }
.aho-muted { color: var(--muted); font-size: .84rem; line-height: 1.7; }
.aho-center { text-align: center; }

.aho-spinner { width: 34px; height: 34px; border-radius: 50%; border: 3px solid rgba(6,182,212,.2); border-top-color: var(--teal); animation: aho-spin .8s linear infinite; display: inline-block; }
.aho-spinner-sm { width: 16px; height: 16px; border-width: 2px; border-color: rgba(255,255,255,.35); border-top-color: #fff; vertical-align: middle; }
@keyframes aho-spin { to { transform: rotate(360deg); } }

.aho-alert { display: flex; align-items: flex-start; gap: .55rem; padding: .85rem 1rem; border-radius: var(--r-md); font-size: .88rem; line-height: 1.6; margin-bottom: 1.1rem; }
.aho-alert-err { background: var(--err-bg); color: #a3271e; }

.aho-blob { position: absolute; border-radius: 50%; filter: blur(70px); pointer-events: none; }
.aho-blob-1 { width: 440px; height: 440px; background: var(--teal); opacity: .3; top: -150px; inset-inline-end: -140px; }
.aho-blob-2 { width: 340px; height: 340px; background: var(--teal-2); opacity: .2; bottom: -150px; inset-inline-start: -100px; }

/* ═════════════ صفحة الدخول ═════════════ */
.aho-auth { min-height: 100vh; min-height: 100dvh; display: grid; grid-template-columns: minmax(380px, 44%) 1fr; }
.aho-auth-brand { position: relative; overflow: hidden; background: linear-gradient(160deg, var(--navy) 0%, var(--navy-2) 55%, var(--navy-3) 100%); color: #fff; padding: 36px clamp(28px, 4vw, 64px); display: flex; }
.aho-auth-brand-inner { position: relative; z-index: 1; display: flex; flex-direction: column; width: 100%; max-width: 520px; }
.aho-auth-top { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: auto; }
.aho-auth-logo { width: 54px; height: 54px; border-radius: 16px; background: #fff; padding: 5px; box-shadow: 0 10px 24px rgba(0,0,0,.25); }
.aho-auth-top-links { display: flex; gap: .4rem; flex-wrap: wrap; }
.aho-auth-top-links a { color: rgba(255,255,255,.8); font-size: .82rem; font-weight: 600; padding: .45rem .85rem; border-radius: 999px; border: 1px solid rgba(255,255,255,.16); transition: background .15s; }
.aho-auth-top-links a:hover { background: rgba(255,255,255,.1); color: #fff; }
.aho-auth-brand h1 { color: #fff; font-size: clamp(2rem, 3vw, 2.75rem); margin: 3rem 0 .8rem; }
.aho-auth-brand-sub { color: rgba(255,255,255,.75); font-size: 1rem; line-height: 1.85; margin-bottom: 2rem; }
.aho-auth-features { list-style: none; margin: 0 0 auto; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.aho-auth-features li { display: flex; align-items: flex-start; gap: .9rem; padding: 1rem 1.1rem; border-radius: var(--r-lg); background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1); }
.aho-auth-feat-ic { flex-shrink: 0; width: 42px; height: 42px; border-radius: 12px; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--teal), var(--teal-2)); box-shadow: 0 8px 18px rgba(6,182,212,.3); }
.aho-auth-features strong { display: block; font-size: .98rem; margin-bottom: .15rem; }
.aho-auth-features small { display: block; color: rgba(255,255,255,.68); font-size: .84rem; line-height: 1.65; }

.aho-auth-main { display: flex; align-items: center; justify-content: center; padding: 40px clamp(20px, 5vw, 80px); }
.aho-auth-card { width: 100%; max-width: 440px; }
.aho-auth-card h2 { font-size: 1.75rem; margin-bottom: .45rem; }
.aho-auth-sub { color: var(--muted); font-size: .92rem; line-height: 1.7; margin-bottom: 1.8rem; }
.aho-label { display: block; font-size: .84rem; font-weight: 700; color: var(--navy); margin: 0 0 .45rem; }
.aho-auth input, .aho-auth select, .aho-form input {
  width: 100%; height: 50px; padding: 0 15px; border: 1.5px solid var(--border); border-radius: var(--r-md); background: #FAFBFD; font-size: 16px; color: var(--text);
  transition: border-color .15s, box-shadow .15s, background .15s; }
.aho-auth input:focus, .aho-auth select:focus, .aho-form input:focus { outline: none; border-color: var(--teal); box-shadow: 0 0 0 3px rgba(6,182,212,.15); background: #fff; }
.aho-auth input.is-invalid { border-color: var(--err); }
.aho-phone-row { display: flex; gap: .5rem; direction: ltr; margin-bottom: 1.15rem; }
.aho-phone-row select { flex: 0 0 44%; padding: 0 10px; font-size: 14px; }
.aho-pass-row { position: relative; margin-bottom: .75rem; }
.aho-pass-row input { padding-inline-end: 50px; }
.aho-pass-toggle { position: absolute; top: 50%; inset-inline-end: 6px; transform: translateY(-50%); width: 40px; height: 40px; border: none; border-radius: 10px; background: transparent; color: var(--faint); cursor: pointer; }
.aho-pass-toggle:hover { color: var(--navy); background: var(--bg); }
.aho-auth-row { display: flex; justify-content: flex-end; margin-bottom: 1.4rem; }
.aho-auth .aho-btn-block { height: 52px; font-size: 1rem; }
.aho-auth-note { display: flex; gap: .55rem; align-items: flex-start; margin-top: 1.4rem; padding: .9rem 1rem; border-radius: var(--r-md); background: var(--info-bg); color: #28579d; font-size: .83rem; line-height: 1.65; }
.aho-auth-foot { margin-top: 1.2rem; text-align: center; color: var(--muted); font-size: .88rem; }

/* ═════════════ اللوحة — الهيكل ═════════════ */
.aho-app { min-height: 100vh; min-height: 100dvh; display: grid; grid-template-columns: 264px 1fr; }
.aho-side { position: sticky; top: 0; height: 100vh; height: 100dvh; background: linear-gradient(180deg, var(--navy) 0%, var(--navy-3) 100%); color: #fff; display: flex; flex-direction: column; padding: 22px 14px; }
.aho-side-brand { display: flex; align-items: center; gap: .7rem; padding: 0 .6rem 1.4rem; margin-bottom: 1rem; border-bottom: 1px solid rgba(255,255,255,.1); }
.aho-side-brand img { width: 40px; height: 40px; border-radius: 12px; background: #fff; padding: 3px; }
.aho-side-brand span { font-weight: 800; font-size: 1.02rem; }
.aho-side-nav { display: flex; flex-direction: column; gap: 4px; flex: 1; }
.aho-side-nav a { position: relative; display: flex; align-items: center; gap: .75rem; padding: .8rem 1rem; border-radius: 14px; color: rgba(255,255,255,.72); font-weight: 600; font-size: .93rem; transition: background .15s, color .15s; }
.aho-side-nav a i { width: 20px; text-align: center; }
.aho-side-nav a:hover { background: rgba(255,255,255,.07); color: #fff; }
.aho-side-nav a.is-active { background: var(--teal); color: #fff; box-shadow: 0 10px 24px rgba(6,182,212,.32); }
.aho-nav-badge { margin-inline-start: auto; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: #FF5A4E; color: #fff; font-size: .72rem; font-weight: 800; display: inline-flex; align-items: center; justify-content: center; }
.aho-nav-badge[hidden] { display: none; }
.aho-side-foot { display: flex; flex-direction: column; gap: 2px; padding-top: 1rem; border-top: 1px solid rgba(255,255,255,.1); }
.aho-side-foot a, .aho-side-foot button { display: flex; align-items: center; gap: .7rem; width: 100%; padding: .65rem 1rem; border-radius: 12px; border: none; background: transparent; color: rgba(255,255,255,.66); font-size: .86rem; font-weight: 600; cursor: pointer; text-align: start; }
.aho-side-foot a:hover, .aho-side-foot button:hover { background: rgba(255,255,255,.07); color: #fff; }
.aho-side-foot form { margin: 0; }

.aho-main { min-width: 0; display: flex; flex-direction: column; }
.aho-topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: .9rem; padding: 16px clamp(18px, 3vw, 40px); background: rgba(243,245,249,.86); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid rgba(231,234,240,.7); }
.aho-topbar-logo { display: none; width: 36px; height: 36px; border-radius: 10px; background: #fff; padding: 3px; box-shadow: var(--shadow-sm); }
.aho-topbar-title { font-size: 1.3rem; flex: 1; }
.aho-topbar-actions { display: flex; align-items: center; gap: .5rem; }
.aho-icon-btn { width: 40px; height: 40px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; background: var(--surface); border: 1px solid var(--border); color: var(--navy); }
.aho-avatar-btn { width: 42px; height: 42px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 2px var(--teal); background: linear-gradient(135deg, var(--teal), var(--navy)); color: #fff; font-weight: 800; cursor: pointer; padding: 0; overflow: hidden; }
.aho-avatar-btn img { width: 100%; height: 100%; object-fit: cover; display: block; }

.aho-content { flex: 1; padding: 24px clamp(18px, 3vw, 40px) 48px; width: 100%; max-width: 1280px; }
.aho-view { display: flex; flex-direction: column; gap: 20px; animation: aho-in .25s var(--ease); }
@keyframes aho-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.aho-state { min-height: 55vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1rem; color: var(--muted); text-align: center; }
.aho-bottom-nav { display: none; }

/* ── بطاقات ── */
.aho-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 20px; box-shadow: var(--shadow-sm); }
.aho-card-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 14px; }
.aho-card-head h3 { font-size: 1rem; display: flex; align-items: center; gap: .55rem; }
.aho-card-head h3 i { color: var(--teal); }
.aho-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
.aho-stack { display: flex; flex-direction: column; gap: 20px; }

/* ── الترحيب ── */
.aho-hero { position: relative; overflow: hidden; display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
  padding: 26px 28px; border-radius: var(--r-xl); color: #fff; background: linear-gradient(120deg, var(--navy) 0%, var(--navy-2) 55%, #0b5a78 100%); box-shadow: var(--shadow-lg); }
.aho-hero::after { content: ''; position: absolute; width: 300px; height: 300px; border-radius: 50%; background: var(--teal); filter: blur(70px); opacity: .35; top: -140px; inset-inline-start: -60px; pointer-events: none; }
.aho-hero > * { position: relative; z-index: 1; }
.aho-hero h2 { color: #fff; font-size: 1.6rem; margin-bottom: .35rem; }
.aho-hero p { color: rgba(255,255,255,.78); font-size: .95rem; }
.aho-hero-code { display: inline-flex; align-items: center; gap: .5rem; padding: .6rem 1.1rem; border-radius: 999px; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.22); color: #fff; font-weight: 700; font-family: ui-monospace, Menlo, monospace; letter-spacing: .03em; cursor: pointer; }
.aho-hero-code:hover { background: rgba(255,255,255,.2); }

/* ── تنبيه الإجراء المطلوب ── */
.aho-action { background: var(--warn-bg); border: 1.5px solid #F4D38F; border-radius: var(--r-lg); padding: 18px; display: flex; flex-direction: column; gap: 12px; }
.aho-action-head { display: flex; align-items: center; gap: .9rem; }
.aho-action-ic { flex-shrink: 0; width: 44px; height: 44px; border-radius: 14px; background: var(--warn); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 1.1rem; animation: aho-ring 2.4s ease-in-out infinite; }
@keyframes aho-ring { 0%, 86%, 100% { transform: rotate(0); } 90% { transform: rotate(12deg); } 94% { transform: rotate(-12deg); } }
.aho-action h3 { font-size: 1.02rem; color: #7a4d05; }
.aho-action p { color: #8a6412; font-size: .86rem; }

/* ── الإحصائيات ── */
.aho-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.aho-stat { display: flex; flex-direction: column; align-items: flex-start; gap: .35rem; padding: 18px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-sm); cursor: pointer; text-align: start; transition: transform .15s var(--ease), box-shadow .15s var(--ease); }
.aho-stat:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.aho-stat-ic { width: 38px; height: 38px; border-radius: 12px; display: flex; align-items: center; justify-content: center; margin-bottom: .3rem; }
.aho-stat b { font-size: 1.8rem; font-weight: 800; color: var(--navy); line-height: 1; }
.aho-stat > span:last-child { color: var(--muted); font-size: .84rem; font-weight: 600; }
.aho-stat-pending .aho-stat-ic { background: var(--warn-bg); color: var(--warn); }
.aho-stat-upcoming .aho-stat-ic { background: var(--info-bg); color: var(--info); }
.aho-stat-done .aho-stat-ic { background: var(--ok-bg); color: var(--ok); }
.aho-stat-certs .aho-stat-ic { background: #E6F8FB; color: var(--teal-2); }

/* ── بطاقة المؤتمر ── */
.aho-conf-list { display: flex; flex-direction: column; gap: 14px; }
.aho-conf { display: flex; gap: 16px; padding: 18px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-sm); }
.aho-card .aho-conf, .aho-action .aho-conf { box-shadow: none; }
.aho-conf.is-pending { border-color: #F4D38F; }
.aho-datebox { flex-shrink: 0; width: 64px; height: 70px; border-radius: 16px; background: linear-gradient(160deg, var(--navy), var(--navy-2)); color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.aho-datebox b { font-size: 1.55rem; font-weight: 800; line-height: 1; }
.aho-datebox span { font-size: .72rem; opacity: .8; margin-top: .25rem; }
.aho-datebox-empty { background: var(--bg); color: var(--faint); }
.aho-conf-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .55rem; }
.aho-conf-head { display: flex; align-items: flex-start; justify-content: space-between; gap: .75rem; }
.aho-conf-head h4 { font-size: 1.05rem; }
.aho-conf-meta { display: flex; flex-wrap: wrap; gap: .35rem 1.1rem; color: var(--muted); font-size: .84rem; }
.aho-conf-meta i { color: var(--faint); margin-inline-end: .2rem; }
.aho-meta-link { color: var(--muted); }
.aho-meta-link:hover { color: var(--teal-2); }
.aho-rel { color: var(--teal-2); }
.aho-rel.is-past { color: var(--faint); }
.aho-conf-role { font-size: .86rem; background: var(--bg); border-radius: 10px; padding: .55rem .8rem; color: var(--text); }
.aho-conf-role i { color: var(--teal-2); }
.aho-conf-help { font-size: .84rem; color: var(--muted); line-height: 1.65; }
.aho-conf-rating { font-size: .84rem; color: var(--muted); display: flex; align-items: center; gap: .5rem; }
.aho-stars { color: #F2A516; letter-spacing: 1px; }
.aho-conf-actions { display: flex; gap: .5rem; flex-wrap: wrap; margin-top: .2rem; }

.aho-badge { flex-shrink: 0; display: inline-flex; align-items: center; padding: .28rem .8rem; border-radius: 999px; font-size: .75rem; font-weight: 800; white-space: nowrap; }
.aho-st-called { background: var(--warn-bg); color: #9a5d00; }
.aho-st-confirmed { background: var(--ok-bg); color: #0b7a4a; }
.aho-st-declined { background: #F0F2F6; color: var(--muted); }
.aho-st-participated { background: #DDF6FA; color: #07758a; }
.aho-st-no_show { background: var(--err-bg); color: #a3271e; }
.aho-st-cancelled, .aho-st-not_called { background: #F0F2F6; color: var(--faint); }

/* ── التصفية ── */
.aho-chips { display: flex; gap: .5rem; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.aho-chips::-webkit-scrollbar { display: none; }
.aho-chip { flex-shrink: 0; display: inline-flex; align-items: center; gap: .45rem; padding: .55rem 1rem; border-radius: 999px; border: 1.5px solid var(--border); background: var(--surface); color: var(--text); font-weight: 700; font-size: .86rem; cursor: pointer; }
.aho-chip span { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: var(--bg); color: var(--muted); font-size: .74rem; display: inline-flex; align-items: center; justify-content: center; }
.aho-chip.is-active { background: var(--navy); border-color: var(--navy); color: #fff; }
.aho-chip.is-active span { background: rgba(255,255,255,.18); color: #fff; }

/* ── الحالة الفارغة ── */
.aho-empty { text-align: center; padding: 28px 16px; }
.aho-empty-ic { width: 56px; height: 56px; margin: 0 auto 12px; border-radius: 18px; background: var(--bg); color: var(--faint); display: flex; align-items: center; justify-content: center; font-size: 1.35rem; }
.aho-empty h4 { font-size: .98rem; color: var(--text); font-weight: 700; line-height: 1.6; }
.aho-empty p { color: var(--muted); font-size: .86rem; margin-top: .35rem; line-height: 1.7; }

/* ── رحلة المنظم ── */
.aho-journey { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; position: relative; }
.aho-journey li { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; gap: .35rem; padding: 0 4px; }
.aho-journey li:not(:last-child)::after { content: ''; position: absolute; top: 22px; inset-inline-start: calc(50% + 26px); width: calc(100% - 42px); height: 2px; background: var(--border); }
.aho-journey li.is-done:not(:last-child)::after { background: var(--teal); }
.aho-journey-ic { width: 44px; height: 44px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--bg); color: var(--faint); border: 2px solid var(--border); position: relative; z-index: 1; }
.aho-journey li.is-done .aho-journey-ic { background: var(--teal); border-color: var(--teal); color: #fff; }
.aho-journey li.is-current .aho-journey-ic { background: #fff; border-color: var(--teal); color: var(--teal); box-shadow: 0 0 0 5px rgba(6,182,212,.15); }
.aho-journey b { font-size: .86rem; color: var(--navy); }
.aho-journey small { font-size: .75rem; color: var(--muted); line-height: 1.5; }
.aho-journey li:not(.is-done):not(.is-current) b { color: var(--faint); }

/* ── الرسائل ── */
.aho-msg-list { display: flex; flex-direction: column; gap: 4px; padding: 10px; }
.aho-msg { display: flex; gap: .85rem; padding: 14px; border-radius: var(--r-md); }
.aho-msg + .aho-msg { border-top: 1px solid var(--border-2); }
.aho-msg.is-new { background: #F0FBFD; }
.aho-msg-ic { flex-shrink: 0; width: 40px; height: 40px; border-radius: 50%; background: var(--navy); color: #fff; display: flex; align-items: center; justify-content: center; font-size: .9rem; }
.aho-msg-body { flex: 1; min-width: 0; }
.aho-msg-top { display: flex; align-items: center; gap: .5rem; margin-bottom: .3rem; flex-wrap: wrap; }
.aho-msg-top b { color: var(--navy); font-size: .9rem; }
.aho-msg-top time { margin-inline-start: auto; color: var(--faint); font-size: .76rem; }
.aho-msg p { white-space: pre-line; font-size: .92rem; line-height: 1.8; color: var(--text); overflow-wrap: anywhere; }
.aho-new { background: var(--teal); color: #fff; font-size: .68rem; font-weight: 800; padding: .12rem .55rem; border-radius: 999px; }

/* ── الشهادات ── */
.aho-cert-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; }
.aho-cert { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; }
.aho-cert-thumb { display: block; aspect-ratio: 1.414; background: var(--bg); overflow: hidden; }
.aho-cert-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s var(--ease); }
.aho-cert-thumb:hover img { transform: scale(1.03); }
.aho-cert-body { padding: 16px; display: flex; flex-direction: column; gap: .3rem; }
.aho-cert-body h4 { font-size: 1rem; }
.aho-cert-body > span { color: var(--muted); font-size: .84rem; }
.aho-cert-actions { display: flex; flex-wrap: wrap; gap: .45rem; margin-top: .6rem; }
.aho-cert-actions .aho-btn { padding: .55rem .9rem; font-size: .82rem; }

/* ── حسابي ── */
.aho-code { font-family: ui-monospace, Menlo, monospace; letter-spacing: .03em; }
.aho-copy { border: 1px solid var(--border); background: var(--surface); color: var(--muted); width: 30px; height: 30px; border-radius: 8px; cursor: pointer; vertical-align: middle; margin-inline-start: .35rem; }
.aho-copy:hover { color: var(--teal-2); border-color: var(--teal); }
.aho-info { margin: 0 0 12px; display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px; }
.aho-info > div { padding: 11px 0; border-bottom: 1px dashed var(--border); min-width: 0; }
.aho-info dt { color: var(--muted); font-size: .78rem; margin-bottom: .25rem; }
.aho-info dt i { color: var(--faint); width: 16px; }
.aho-info dd { margin: 0; font-weight: 700; font-size: .92rem; color: var(--text); overflow-wrap: anywhere; line-height: 1.6; }
.aho-tag { display: inline-block; background: #E6F8FB; color: #07758a; padding: .15rem .6rem; border-radius: 999px; font-size: .76rem; margin: 0 0 .25rem .2rem; }
.aho-form { display: flex; flex-direction: column; gap: 12px; }
.aho-form label { display: flex; flex-direction: column; gap: .4rem; font-size: .84rem; font-weight: 700; color: var(--navy); }
.aho-form .aho-btn { align-self: flex-start; }
.aho-form-msg { padding: .7rem .9rem; border-radius: 10px; font-size: .86rem; }
.aho-form-msg.is-ok { background: var(--ok-bg); color: #0b6b41; }
.aho-form-msg.is-err { background: var(--err-bg); color: #a3271e; }
.aho-faq { display: flex; flex-direction: column; gap: 8px; margin-bottom: 16px; }
.aho-faq details { border: 1px solid var(--border); border-radius: var(--r-md); background: #FAFBFD; }
.aho-faq summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 14px 16px; font-weight: 700; font-size: .92rem; color: var(--navy); }
.aho-faq summary::-webkit-details-marker { display: none; }
.aho-faq summary i { color: var(--faint); transition: transform .2s var(--ease); }
.aho-faq details[open] summary i { transform: rotate(180deg); }
.aho-faq details p { padding: 0 16px 14px; color: var(--muted); font-size: .88rem; line-height: 1.8; }

/* ── إشعار ونافذة تأكيد ── */
.aho-toast { position: fixed; z-index: 100000; bottom: 28px; left: 50%; transform: translate(-50%, 20px); opacity: 0; pointer-events: none; padding: .85rem 1.3rem; border-radius: 14px; background: var(--navy); color: #fff; font-weight: 700; font-size: .9rem; box-shadow: var(--shadow-lg); transition: opacity .2s, transform .2s var(--ease); max-width: calc(100vw - 32px); }
.aho-toast.is-show { opacity: 1; transform: translate(-50%, 0); }
.aho-toast.is-ok { background: var(--ok); }
.aho-toast.is-err { background: var(--err); }
.aho-modal { position: fixed; inset: 0; z-index: 100001; background: rgba(7,29,51,.55); backdrop-filter: blur(3px); display: flex; align-items: center; justify-content: center; padding: 16px; }
.aho-modal[hidden] { display: none; }
.aho-modal-card { width: 100%; max-width: 420px; background: #fff; border-radius: 24px; padding: 28px 24px 22px; text-align: center; box-shadow: var(--shadow-lg); animation: aho-pop .2s var(--ease); }
@keyframes aho-pop { from { opacity: 0; transform: scale(.96) translateY(8px); } to { opacity: 1; transform: none; } }
.aho-modal-ic { width: 60px; height: 60px; margin: 0 auto 14px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.6rem; }
.aho-modal-ic.is-success { background: var(--ok-bg); color: var(--ok); }
.aho-modal-ic.is-danger { background: var(--err-bg); color: var(--err); }
.aho-modal-card h3 { font-size: 1.15rem; margin-bottom: .5rem; }
.aho-modal-card p { color: var(--muted); font-size: .92rem; line-height: 1.75; margin-bottom: 1.3rem; }
.aho-modal-actions { display: flex; gap: .6rem; }
.aho-modal-actions .aho-btn { flex: 1; height: 48px; }

/* ═════════════ الأجهزة اللوحية والهاتف ═════════════ */
@media (max-width: 1100px) {
  .aho-stats { grid-template-columns: repeat(2, 1fr); }
  .aho-grid-2 { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  /* الدخول: الهوية أعلى الصفحة بشكل مختصر */
  .aho-auth { grid-template-columns: 1fr; }
  .aho-auth-brand { padding: 22px 18px 26px; }
  .aho-auth-brand h1 { margin: 1.4rem 0 .4rem; font-size: 1.75rem; }
  .aho-auth-brand-sub { margin-bottom: 0; font-size: .92rem; }
  .aho-auth-features { display: none; }
  .aho-auth-main { align-items: flex-start; padding: 26px 18px 40px; }

  /* اللوحة: شريط سفلي بدل الجانبي */
  .aho-app { grid-template-columns: 1fr; padding-bottom: calc(72px + env(safe-area-inset-bottom)); }
  .aho-side { display: none; }
  .aho-topbar { padding: 12px 16px; }
  .aho-topbar-logo { display: block; }
  .aho-topbar-title { font-size: 1.1rem; }
  .aho-content { padding: 16px 14px 28px; }
  .aho-view { gap: 14px; }
  .aho-bottom-nav { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; position: fixed; bottom: 0; left: 0; right: 0; z-index: 50;
    background: rgba(255,255,255,.96); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-top: 1px solid var(--border);
    padding: 6px 4px calc(6px + env(safe-area-inset-bottom)); box-shadow: 0 -6px 20px rgba(16,35,58,.06); }
  .aho-bottom-nav a { position: relative; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 6px 2px; border-radius: 12px; color: var(--faint); font-size: .68rem; font-weight: 700; text-align: center; line-height: 1.2; }
  .aho-bottom-nav a i { font-size: 1.12rem; }
  .aho-bottom-nav a.is-active { color: var(--teal-2); }
  .aho-bottom-nav a.is-active i { transform: translateY(-1px); }
  .aho-bottom-nav .aho-nav-badge { position: absolute; top: 0; inset-inline-end: calc(50% - 22px); min-width: 18px; height: 18px; font-size: .64rem; margin: 0; border: 2px solid #fff; }
  .aho-toast { bottom: calc(86px + env(safe-area-inset-bottom)); }

  .aho-hero { padding: 20px; border-radius: 22px; }
  .aho-hero h2 { font-size: 1.3rem; }
  .aho-card { padding: 16px; border-radius: 18px; }
  .aho-conf { padding: 14px; gap: 12px; }
  .aho-datebox { width: 54px; height: 60px; border-radius: 14px; }
  .aho-datebox b { font-size: 1.3rem; }
  .aho-conf-head { flex-direction: column; gap: .4rem; }
  .aho-conf-actions .aho-btn { flex: 1 1 auto; }
  .aho-stats { gap: 10px; }
  .aho-stat { padding: 14px; }
  .aho-stat b { font-size: 1.5rem; }
  .aho-journey { grid-template-columns: 1fr; gap: 0; }
  .aho-journey li { flex-direction: row; text-align: start; gap: .8rem; padding: 6px 0; flex-wrap: wrap; }
  .aho-journey li b { min-width: 90px; }
  .aho-journey li small { flex-basis: calc(100% - 60px); margin-inline-start: 56px; margin-top: -10px; }
  .aho-journey li:not(:last-child)::after { top: 50px; inset-inline-start: 21px; width: 2px; height: calc(100% - 44px); }
  .aho-info { grid-template-columns: 1fr; }
  .aho-cert-grid { grid-template-columns: 1fr; }
  .aho-modal { align-items: flex-end; padding: 0; }
  .aho-modal-card { max-width: none; border-radius: 24px 24px 0 0; padding-bottom: calc(22px + env(safe-area-inset-bottom)); }
}

/* ── الموظف (1.9.0) ── */
.aho-emp-badge { display: inline-flex; align-items: center; gap: .4rem; padding: .3rem .8rem; margin-bottom: .6rem; border-radius: 999px; background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.26); color: #fff; font-size: .8rem; font-weight: 700; }
.aho-emp-card { border-color: #C7D2FE; background: linear-gradient(180deg, #F7F8FF, #fff); }
.aho-emp-card .aho-card-head h3 i { color: #4338CA; }

/* ── أزرار الشهادة (1.11.0): تحميل PDF / صورة، مشاركة، التحقق ── */
.aho-cert-actions { display: grid; grid-template-columns: 1fr 1fr; }
.aho-cert-actions .aho-btn { justify-content: center; text-align: center; }

/* ═════════════ عهدتي (1.14.0) ═════════════ */
.aho-cu-intro { display: flex; gap: .5rem; align-items: flex-start; line-height: 1.7; }
.aho-cu-alert { flex-direction: row; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.aho-cu-table { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--r-md); }
.aho-cu-table table { width: 100%; border-collapse: collapse; font-size: .86rem; }
.aho-cu-table th, .aho-cu-table td { padding: .6rem .75rem; text-align: start; border-bottom: 1px solid var(--border-2); vertical-align: top; }
.aho-cu-table th { background: #F7F9FC; color: var(--muted); font-size: .76rem; font-weight: 800; white-space: nowrap; }
.aho-cu-table tr:last-child td { border-bottom: 0; }
.aho-cu-table td small { display: block; color: var(--muted); font-size: .76rem; margin-top: 2px; }
.aho-cu-pending { border: 2px solid #F4D38F; }
.aho-cu-pending .aho-card-head h3 { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; }
.aho-cu-h { margin: 16px 0 8px !important; font-size: .95rem; }
.aho-cu-pledge { white-space: pre-line; background: #FBFCFE; border: 1px solid var(--border); border-radius: var(--r-md); padding: 14px 16px; line-height: 1.95; font-family: 'Tajawal', sans-serif; font-size: .92rem; max-height: 340px; overflow-y: auto; text-align: right; }
.aho-cu-form { margin-top: 14px; display: flex; flex-direction: column; gap: 12px; }
.aho-cu-agree { display: flex !important; flex-direction: row !important; gap: .6rem; align-items: flex-start; font-weight: 600; line-height: 1.6; background: var(--ok-bg); border-radius: var(--r-md); padding: 12px; cursor: pointer; }
.aho-cu-agree input { width: 20px; height: 20px; margin-top: 2px; flex-shrink: 0; accent-color: var(--ok); }
.aho-small { font-size: .78rem; }
.aho-cu-records { display: flex; flex-direction: column; }
.aho-cu-rec { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--border-2); }
.aho-cu-rec:last-child { border-bottom: 0; }
.aho-cu-rec small { display: block; color: var(--muted); font-size: .78rem; margin-top: 2px; }
@media (max-width: 900px) {
  .aho-bottom-nav a span { font-size: .62rem; }
  .aho-cu-rec { flex-direction: column; align-items: stretch; }
}
.aho-cu-table .aho-code { white-space: nowrap; }

/* ═════════════ أيام الحضور (1.15.0) ═════════════ */
#aho-modal-text { white-space: pre-line; }
.aho-days { margin-top: 10px; display: flex; flex-direction: column; gap: 8px; background: #F7FAFC; border: 1px solid var(--border); border-radius: var(--r-md); padding: 12px; }
.aho-days > b { color: var(--navy); font-size: .9rem; }
.aho-days > small { line-height: 1.6; }
.aho-days-list { display: flex; flex-wrap: wrap; gap: 8px; }
.aho-day-pick { display: inline-flex; align-items: center; gap: .45rem; padding: .5rem .8rem; border: 1.5px solid var(--border); border-radius: 999px; background: #fff; cursor: pointer; font-weight: 700; font-size: .85rem; }
.aho-day-pick:has(input:checked) { border-color: var(--ok); background: var(--ok-bg); color: #0b7a4a; }
.aho-day-pick input { width: 17px; height: 17px; accent-color: var(--ok); margin: 0; }
.aho-day { display: inline-flex; align-items: center; gap: .35rem; padding: .35rem .7rem; border-radius: 999px; font-size: .8rem; font-weight: 700; }
.aho-day.is-on { background: var(--ok-bg); color: #0b7a4a; }
.aho-day.is-off { background: #EEF1F5; color: var(--faint); text-decoration: line-through; }
.aho-days .aho-btn { align-self: flex-start; }
