/* Header Tidy v3 — شريط هيدر مضغوط ومنظم في صف واحد على كل الشاشات
   يُحمَّل بعد كل ملفات الهيدر ليلغي التعارضات (style.css / home-qa.css). */
.top.site-header .top-in{display:flex!important;flex-wrap:nowrap!important;align-items:center;gap:12px;height:auto;min-height:60px;padding-block:0}
.top.site-header .brand{flex:none;min-width:0;display:inline-flex;align-items:center;gap:8px}
.top.site-header .brand img{max-height:34px;width:auto}
.top.site-header .brand-mark{width:34px;height:34px}
.top.site-header .brand-name{font-size:18px;white-space:nowrap}

/* روابط التنقل: كبسولة واحدة في الوسط */
.top.site-header .nav{display:flex;align-items:center;gap:2px;margin:0 auto;padding:4px;width:auto;flex-wrap:nowrap;overflow:visible;border-radius:999px;background:color-mix(in srgb,var(--ink) 4%,transparent);border:1px solid color-mix(in srgb,var(--border) 60%,transparent)}
.top.site-header .nav>a,.top.site-header .header-more>summary{display:inline-flex;align-items:center;gap:6px;min-height:34px;height:auto;padding:6px 12px;font-size:.88rem;line-height:1;white-space:nowrap;border-radius:999px;text-align:start}
.top.site-header .nav>a>.i,.top.site-header .nav>a svg{width:16px;height:16px;display:inline-block}
.top.site-header .nav>a.nav-qa-link{display:none} /* موجود داخل "المزيد" لتقليل الزحام */
.top.site-header .header-more{position:relative}
.top.site-header .header-more>summary{list-style:none;cursor:pointer}
.top.site-header .header-more>summary::-webkit-details-marker{display:none}

/* الأزرار يسار الشريط */
.top.site-header .nav-actions{display:flex;align-items:center;gap:6px;flex:none;margin:0}
.top.site-header .nav-actions .btn.sm,.top.site-header .tsw-btn,.top.site-header .umenu-btn{min-height:36px;height:36px;padding-block:0;font-size:.86rem}
.top.site-header .auth-actions{display:flex;align-items:center;gap:6px;flex:none}
.top.site-header .auth-actions .btn{white-space:nowrap}

/* النصوص الطويلة/القصيرة: الطويلة افتراضًا، والقصيرة على الشاشات الصغيرة */
.top.site-header .auth-actions .lbl-short{display:none}

/* جوال وتابلت: زر القائمة + الشعار + الأزرار فقط، والروابط داخل القائمة الجانبية */
@media (max-width:960px){
  .top.site-header .nav{display:none!important}
  .top.site-header .nav-burger{display:inline-flex;width:38px;height:38px}
  .top.site-header .top-in{gap:8px;min-height:56px}
  .top.site-header .nav-actions{margin-inline-start:auto}
}
@media (max-width:560px){
  .top.site-header .top-in{min-height:52px}
  .top.site-header .brand img{max-height:28px}
  .top.site-header .brand-mark{width:30px;height:30px}
  .top.site-header .brand-name{font-size:16px}
  .top.site-header .nav-actions .hide-sm{display:none}
  .top.site-header .nav-actions .btn.sm,.top.site-header .tsw-btn,.top.site-header .umenu-btn{height:34px;min-height:34px;padding-inline:10px}

  /* زر تسجيل الدخول يبقى ظاهرًا دائمًا (يتعارض مع قاعدة header-pro.css القديمة) */
  .top.site-header .auth-actions{gap:5px}
  .top.site-header .auth-actions .btn.ghost{display:inline-flex}
  .top.site-header .auth-actions .btn.sm{height:34px;min-height:34px;padding:0 11px;font-size:.8rem;border-radius:10px}
  .top.site-header .auth-actions .lbl-full{display:none}
  .top.site-header .auth-actions .lbl-short{display:inline}
}

/* زر القائمة (الثلاث شرطات): مرتب ومتمركز، ويُنقل لجهة الأزرار بدل ما يكون فوق الشعار */
.top.site-header .nav-burger{order:10;flex:none;width:38px;height:38px;padding:0;margin:0;border-radius:10px;border:1px solid var(--border);background:color-mix(in srgb,var(--surface) 85%,transparent);color:var(--ink);display:none;flex-direction:column;align-items:center;justify-content:center;gap:4px;line-height:0;box-shadow:none}
.top.site-header .nav-burger span{display:block!important;width:18px;height:2px;margin:0;border-radius:2px;background:currentColor;flex:none}
.top.site-header .nav-burger[aria-expanded=true] span:nth-child(1){transform:translateY(6px) rotate(45deg)}
.top.site-header .nav-burger[aria-expanded=true] span:nth-child(2){opacity:0}
.top.site-header .nav-burger[aria-expanded=true] span:nth-child(3){transform:translateY(-6px) rotate(-45deg)}
.top.site-header .brand{order:1}
.top.site-header .nav{order:2}
.top.site-header .nav-actions{order:3}
@media (min-width:961px){.top.site-header .nav-burger{display:none!important}}
@media (max-width:960px){.top.site-header .nav-burger{display:inline-flex!important}}
