/* مكوّن التبويبات المشترك بين الموقع العامّ ولوحة التحكّم: .tabset > .tablist + .tabpanel. يقرأ الألوان من tokens.css وحدها. */
.tablist {
  display: flex; gap: 6px; padding: 5px; width: fit-content; max-width: 100%; overflow-x: auto; scrollbar-width: none;
  border: 1px solid var(--line); border-radius: 999px; background: var(--surface-2);
}
.tablist::-webkit-scrollbar { display: none; }
.tab {
  display: inline-flex; align-items: center; gap: 8px; padding: 10px 20px; border: 0; border-radius: 999px; background: none;
  color: var(--muted); font-family: inherit; font-size: .94rem; font-weight: 700; white-space: nowrap; cursor: pointer; text-decoration: none;
  transition: background var(--transition), color var(--transition), box-shadow var(--transition);
}
.tab:hover { color: var(--ink); }
.tab[aria-selected="true"], .tab[aria-current="page"] { background: var(--card); color: var(--brand); box-shadow: var(--shadow-xs), 0 0 0 1px var(--line); }
.tab .icon-svg { width: 18px; height: 18px; }
.tab-count {
  min-width: 22px; padding: 1px 7px; border-radius: 999px; background: var(--line); color: var(--muted);
  font-size: .74rem; font-weight: 800; text-align: center;
}
.tab[aria-selected="true"] .tab-count, .tab[aria-current="page"] .tab-count { background: var(--brand); color: var(--on-brand); }
.tabpanel { margin-top: var(--space-6); }
.tabpanel[hidden] { display: none; }
.tabpanel:not([hidden]) { animation: tab-in .28s var(--ease-out) both; }
@keyframes tab-in { from { opacity: 0; transform: translateY(6px); } }
@media (prefers-reduced-motion: reduce) { .tabpanel:not([hidden]) { animation: none; } }
@media (max-width: 600px) {
  .tablist { width: 100%; }
  .tab { flex: 1; justify-content: center; padding: 10px 12px; font-size: .86rem; }
}
@media (max-width: 480px) {
  .tab { gap: 6px; padding: 10px 10px; font-size: .82rem; }
  .tab .icon-svg { display: none; }
}
